NAME
touch - change access and modification times of files
SYNOPSIS
touch [-acm] [-r file] [-t [[CC]YY]MMDDhhmm[.SS]] file...
DESCRIPTION
touch sets the access and modification timestamps of files. By default, both the access and modification times are set to the current time. If necessary, files will be created.
touch exits successfully if and only if all timestamps could be set successfully.
OPTIONS
touch accepts the following options:
- -a
-
Set the access time of the specified files only, unless -m is given as well.
- -c
-
Do not create non-existing files. No warning is generated, and it will not influence the exit status.
- -f
-
This option is ignored, and only recognized for compatibility reasons.
- -m
-
Set the modification time of the specified files only, unless -a is given as well.
- -r file
-
Use the access and modification time of file instead of the current time.
- -t [[CC]YY]MMDDhhmm[.SS]
-
Set the access and modification times to the specified time. If YY is present, but CC is not, then CC is assumed to be 19 if YY is larger than 69, and 20 otherwise. If YY is not present, the current year is assumed.
It should be noted that many systems cannot deal with timestamps before Jan 1, 1970 or after Jan 19, 2038.
ENVIRONMENT
The working of touch is not influenced by any environment variables.
BUGS
touch uses Time::Local
to translate the time format to epoch seconds
STANDARDS
This touch implementation is compatible with the OpenBSD implementation.
AUTHOR
The Perl implementation of touch was written by Abigail, perlpowertools@abigail.be.
COPYRIGHT and LICENSE
This program is copyright by Abigail 1999.
This program is free and open software. You may use, copy, modify, distribute and sell this program (and any modified variants) in any way you wish, provided you do not restrict others to do the same.