2014-02-11 00:35:16 +00:00
|
|
|
# touch
|
|
|
|
|
|
|
|
> Change a file access and modification times (atime, mtime)
|
|
|
|
|
2015-12-31 13:11:18 +00:00
|
|
|
- Create a new empty file(s) or change the times for existing file(s) to current time
|
2014-02-11 00:35:16 +00:00
|
|
|
|
|
|
|
`touch {{filename}}`
|
|
|
|
|
2015-10-22 08:31:52 +01:00
|
|
|
- Set the times on a file to those specified
|
2014-02-11 00:35:16 +00:00
|
|
|
|
2015-12-31 13:11:18 +00:00
|
|
|
`touch -t 201412250801.59 {{filename}}`
|
|
|
|
`touch -t {{YYYYMMDDHHMM.SS}} {{filename}}`
|
2014-02-11 00:35:16 +00:00
|
|
|
|
|
|
|
- Set the times on a file to match those on second file
|
|
|
|
|
|
|
|
`touch -r {{filename2}} {{filename}}`
|