| OLD | NEW |
| 1 #!/usr/bin/env python | 1 #!/usr/bin/env python |
| 2 # | 2 # |
| 3 # Copyright (c) 2012 Google Inc. All rights reserved. | 3 # Copyright (c) 2012 Google Inc. All rights reserved. |
| 4 # Use of this source code is governed by a BSD-style license that can be | 4 # Use of this source code is governed by a BSD-style license that can be |
| 5 # found in the LICENSE file. | 5 # found in the LICENSE file. |
| 6 | 6 |
| 7 import os | 7 import os |
| 8 import sys | 8 import sys |
| 9 | 9 |
| 10 """Cross-platform touch.""" | 10 """Cross-platform touch.""" |
| 11 | 11 |
| 12 for fname in sys.argv[1:]: | 12 for fname in sys.argv[1:]: |
| 13 if os.path.exists(fname): | 13 if os.path.exists(fname): |
| 14 os.utime(fname, None) | 14 os.utime(fname, None) |
| 15 else: | 15 else: |
| 16 open(fname, 'w').close() | 16 open(fname, 'w').close() |
| OLD | NEW |