music |
| | OSdata.com |
touch
summary
This subchapter looks at touch, a Unix (and Linux) command.
Use touch to change the date stamp on a file.
touch
This subchapter looks at touch, a Unix (and Linux) command.
Use touch to change the date stamp on a file.
The most common use of touch is to force make to recompile a particular file (or group of files).
how to use
The simple form of touch changes a named files timestamp to the current date and time:
$ touch filename
multiple files
Use touch to change all of the files in a directory:
$ touch *
specific time
You can use touch to set a specific time by using the -t option. The following command sets a file to the Solstice at the end of the Mayan calendar (11:12 a.m. December 21, 2012):
$ touch -t201212211112.00 filename
The following command sets a file to the noon on January 1, 2012:
$ touch -t201201011200.00 filename
The format is YYYYMMDDhhmm.ss, YYYY = four digit year, MM - two digit month, DD = two digit day, hh = two digit hour (24 hour clock), mm = two digit month, and ss = two digit second.
create an empty file
You can use touch to create an empty file. Simply issue the touch command with the desired file name.
$ touch filename
This will create an empty file with the designated file name.
Why would you want to do this? One common reason is to create an expected file. Some scripts will check for the existence of particular files and choke if they cant find them. If the script does not need particular data alreazdy stored in the file (for example, it will be appending data intot he file or it is simply checking for the existence of the file), then touch is your fast and easy method for creating the expected file (as an empty file).
comments, suggestions, corrections, criticisms
free music player coding example
Coding example: I am making heavily documented and explained open source code for a method to play music for free almost any song, no subscription fees, no download costs, no advertisements, all completely legal. This is done by building a front-end to YouTube (which checks the copyright permissions for you).
View music player in action: www.musicinpublic.com/.
Create your own copy from the original source code/ (presented for learning programming).
This section is under the category of owning cirticism.
In response to a posting about my article collecting social media, Moderator +Andrew Smith (Technology addict, Web Developer, API guru, futsal and football wannabe, and all round nice guy!, Swordfox Design, arrowtown, new zealand) of the Google+ community Web Developers, Web Designers, Web Coding claims Quite frankly this is self promotion, and your site is not of great quality. I can see how +Joost SchuurÊ would think this of not high enough a standard.
Because I no longer have the computer and software to make PDFs, the book is available as an HTML file, which you can convert into a PDF.
Names and logos of various OSs are trademarks of their respective owners.