Misplaced Pages

Touch (command): Difference between revisions

Article snapshot taken from Wikipedia with creative commons attribution-sharealike license. Give it a read and then ask your questions in the chat. We can research this topic together.
Browse history interactively← Previous editNext edit →Content deleted Content addedVisualWikitext
Revision as of 23:38, 8 January 2019 editGhettoblaster (talk | contribs)Extended confirmed users19,867 editsmNo edit summary← Previous edit Revision as of 13:46, 27 January 2019 edit undoGhettoblaster (talk | contribs)Extended confirmed users19,867 editsNo edit summaryNext edit →
Line 1: Line 1:
{{lowercase|title=touch (Unix)}}
{{Infobox Software {{Infobox Software
| name = touch | name = touch
Line 5: Line 6:
| screenshot size = | screenshot size =
| caption = | caption =
| developer = Paul Rubin, Arnold Robbins, Jim Kingdon, David MacKenzie, Kris Heidenstrom | developer = Paul Rubin, Arnold Robbins, Jim Kingdon, David MacKenzie, Randy Smith, Kris Heidenstrom
| released = {{Start date and age|1979|1}} | released = {{Start date and age|1979|1}}
| latest release version = | latest release version =
| latest release date = | latest release date =
| operating system = ] and ], ], ], ] | operating system = ] and ], ], ], ], ]
| genre = ] | genre = ]
| license = | license =
| website = | website =
}} }}
In ], '''<code>touch</code>''' is a ] in ] and ] ]s used to update the access date and/or modification date of a ] or ]. The command is also available in the ] shell<ref>http://aros.sourceforge.net/documentation/users/shell/index.php</ref>, the ] shell<ref>{{cite book|author=Paul S. Dayan|year=1992|title=The OS-9 Guru - 1 : The Facts|publisher=Galactic Industrial Limited|isbn=0-9519228-0-7}}</ref> and for ].<ref>http://www.ibiblio.org/pub/micro/pc-stuff/freedos/files/distributions/1.2/repos/pkg-html/group-util.html</ref> In ], '''<code>touch</code>''' is a ] in ] and ] ]s, the ] shell<ref>http://aros.sourceforge.net/documentation/users/shell/index.php</ref>, and the ] shell<ref>{{cite book|author=Paul S. Dayan|year=1992|title=The OS-9 Guru - 1 : The Facts|publisher=Galactic Industrial Limited|isbn=0-9519228-0-7}}</ref> used to update the access date and/or modification date of a ] or ]. The command is also available for ]<ref>http://www.ibiblio.org/pub/micro/pc-stuff/freedos/files/distributions/1.2/repos/pkg-html/group-util.html</ref> and ].<ref></ref>
In its default usage, it is the equivalent of creating or opening a file and saving it without any change to the file contents. Touch avoids opening, saving, and closing the file. Instead it simply updates the dates associated with the file or directory. An updated access or modification date can be important for a variety of other programs such as ] utilities or the ] command-line interface programming utility. Typically these types of programs are only concerned with files which have been created or modified after the program was last run. Touch can also be useful for quickly creating files for programs or scripts that require a file with a specific name to exist for successful operation of the program, but do not require the file to have any specific content.


==Overview== ==Overview==
In its default usage, it is the equivalent of creating or opening a file and saving it without any change to the file contents. <code>touch</code> avoids opening, saving, and closing the file. Instead it simply updates the dates associated with the file or directory. An updated access or modification date can be important for a variety of other programs such as ] utilities or the ] command-line interface programming utility. Typically these types of programs are only concerned with files which have been created or modified after the program was last run. The <code>touch</code> command can also be useful for quickly creating files for programs or scripts that require a file with a specific name to exist for successful operation of the program, but do not require the file to have any specific content.
A touch utility appeared in ] ]. The version of <tt>touch</tt> bundled in ] ] was written by Paul Rubin, Arnold Robbins, Jim Kingdon, and David MacKenzie.


The ] (SUS) specifies that <tt>touch</tt> should change the access times, modification times, or both, for a file. The file is identified by a pathname supplied as a single argument. It also specifies that if the file identified does not exist, the file is created and the access and modification times are set as specified. If no new timestamps are specified, <tt>touch</tt> uses the current time. The ] (SUS) specifies that <code>touch</code> should change the access times, modification times, or both, for a file. The file is identified by a pathname supplied as a single argument. It also specifies that if the file identified does not exist, the file is created and the access and modification times are set as specified. If no new timestamps are specified, <code>touch</code> uses the current time.


==History==
Programs that perform similar operations as the Unix <code>touch</code> utility are available for other operating systems, including ]<ref></ref> and the ].{{which|date=January 2015 <!-- a short list here would be very useful -->}} A <code>touch</code> utility first appeared in ] ]. Today, the command is available for a number of different operating systems, including many ] and ] systems, ], ] and the ].{{which|date=January 2015 <!-- a short list here would be very useful -->}}


The version of <code>touch</code> bundled in ] ] was written by Paul Rubin, Arnold Robbins, Jim Kingdon, David MacKenzie, and Randy Smith.<ref>https://linux.die.net/man/1/touch</ref>
The ] version was developed by Kris Heidenstrom.<ref>http://www.ibiblio.org/pub/micro/pc-stuff/freedos/files/distributions/1.2/repos/pkg-html/touch.html</ref>

The command is available as a separate package for ] as part the ] collection of ] ] ] of common ] ] ].<ref>http://unxutils.sourceforge.net/</ref> The ] version was developed by Kris Heidenstrom.<ref>http://www.ibiblio.org/pub/micro/pc-stuff/freedos/files/distributions/1.2/repos/pkg-html/touch.html</ref>


==See also== ==See also==
*] *]
*] *]


==References== ==References==
Line 40: Line 43:


{{Use dmy dates|date=March 2014}} {{Use dmy dates|date=March 2014}}
{{lowercase|title=touch (Unix)}}


] ]

Revision as of 13:46, 27 January 2019

touch
Developer(s)Paul Rubin, Arnold Robbins, Jim Kingdon, David MacKenzie, Randy Smith, Kris Heidenstrom
Initial releaseJanuary 1979; 45 years ago (1979-01)
Operating systemUnix and Unix-like, AROS, OS-9, FreeDOS, Microsoft Windows
TypeCommand

In computing, touch is a command in Unix and Unix-like operating systems, the AROS shell, and the OS-9 shell used to update the access date and/or modification date of a computer file or directory. The command is also available for FreeDOS and Microsoft Windows.

Overview

In its default usage, it is the equivalent of creating or opening a file and saving it without any change to the file contents. touch avoids opening, saving, and closing the file. Instead it simply updates the dates associated with the file or directory. An updated access or modification date can be important for a variety of other programs such as backup utilities or the make command-line interface programming utility. Typically these types of programs are only concerned with files which have been created or modified after the program was last run. The touch command can also be useful for quickly creating files for programs or scripts that require a file with a specific name to exist for successful operation of the program, but do not require the file to have any specific content.

The Single Unix Specification (SUS) specifies that touch should change the access times, modification times, or both, for a file. The file is identified by a pathname supplied as a single argument. It also specifies that if the file identified does not exist, the file is created and the access and modification times are set as specified. If no new timestamps are specified, touch uses the current time.

History

A touch utility first appeared in Version 7 AT&T UNIX. Today, the command is available for a number of different operating systems, including many Unix and Unix-like systems, DOS, Microsoft Windows and the classic Mac OS.

The version of touch bundled in GNU coreutils was written by Paul Rubin, Arnold Robbins, Jim Kingdon, David MacKenzie, and Randy Smith.

The command is available as a separate package for Microsoft Windows as part the UnxUtils collection of native Win32 ports of common GNU Unix-like utilities. The FreeDOS version was developed by Kris Heidenstrom.

See also

References

  1. http://aros.sourceforge.net/documentation/users/shell/index.php
  2. Paul S. Dayan (1992). The OS-9 Guru - 1 : The Facts. Galactic Industrial Limited. ISBN 0-9519228-0-7.
  3. http://www.ibiblio.org/pub/micro/pc-stuff/freedos/files/distributions/1.2/repos/pkg-html/group-util.html
  4. touch for Windows
  5. https://linux.die.net/man/1/touch
  6. http://unxutils.sourceforge.net/
  7. http://www.ibiblio.org/pub/micro/pc-stuff/freedos/files/distributions/1.2/repos/pkg-html/touch.html

External links

Unix command-line interface programs and shell builtins
File system
Processes
User environment
Text processing
Shell builtins
Searching
Documentation
Software development
Miscellaneous

Categories: