3 touch \- change file access and modification times
5 \fBtouch\fR [\fB\-c\fR] [\fB\-a\fR] [\fB\-m\fR] [\fB\-r\fR file] [\fB\-t\fR [CC[YY]]MMDDhhmm[.ss]] [MMDDhhmm[YY]] \fIfile\fR ...\fR
18 .FL "\-c" "Do not create the file if it doesn't already exist"
19 .FL "\-a" "Change access time"
20 .FL "\-m" "Change modification time"
21 .FL "\-r file" "Apply time of specified file"
22 .FL "\-t [CC[YY]]MMDDhhmm[.ss]]" "Apply time specified"
23 .FL "\-t [MMDDhhmm[YY]]" "Apply time specified (alternate form)"
25 .EX "touch *.h" "Make the \fI.h\fP files look recent"
26 .EX "touch -t 199610010000 *" "Change date and time of all files in current directory to midnight Oct 1, 1996"
29 With no options specified, the times of last modification and last access
30 are set to the current time.
31 This command is mostly used to trick
33 into thinking that a file is more recent than it really is.
34 If the file being touched does not exist, it is created, unless the \fB\-c\fR
37 The \fB\-a\fR or \fB\-m\fR flag may be used to change only the access or
38 modification time. The \fB\-r\fR or \fB\-t\fR flag may be used to change
39 the times to match the times of another file or to a specified time.
44 Original author unknown. Rewritten for POSIX by Peter Holzer
45 (hp@vmars.tuwien.ac.at).
46 .\" man page updated by A. S. Woodhull 2005-01-15