December 1999
Beginner
528 pages
11h 10m
English
Format:
touch options filename
Option:
| -t MMDDhhmm | Create a file with a month, day, hour, minute, date stamp |
This creates a file with a current or new date stamp.
$ touch myfile
$ ls -l myfile
-rw-r--r-- 1 dave admin 0 Jun 30 09:59 myfile
The above creates a new empty file with today’s date/time called myfile.
$ touch -t 06100930 myfile2
$ ls -l myfile2
-rw-r--r-- 1 dave admin 0 Jun 10 09:30 myfile2
The above creates a new empty file called myfile2 with the date stamp of June 10 at 09:30am.
Read now
Unlock full access