On Wed, May 25, 2005 at 11:28:04AM +0100, michael wrote: > On Wed, 2005-05-25 at 12:00 +0200, Urs Thuermann wrote: > > : > /etc/mtab > > what's the ':' do???
Nothing. At least hardly anything worth mentioning. See this snippet from the bash manual: ##### SHELL BUILTIN COMMANDS : [arguments] No effect; the command does nothing beyond expanding arguments and performing any specified redirections. A zero exit code is returned. ##### That also means it doesn't have any output. This empty output is now redirected to /etc/mtab, making that file empty. You can try other methods as well, e.g. 'cat /dev/null > /etc/mtab'. [EMAIL PROTECTED]:~$ echo "Hello World" > temp [EMAIL PROTECTED]:~$ cat temp Hello World [EMAIL PROTECTED]:~$ : > temp [EMAIL PROTECTED]:~$ cat temp [EMAIL PROTECTED]:~$ Does anyone know any other uses for this ':' command? HTH, -- Maurits van Rees | http://maurits.vanrees.org/ [Dutch/Nederlands] Public GnuPG key: keyserver.net ID 0x1735C5C2 "Let your advance worrying become advance thinking and planning." - Winston Churchill
signature.asc
Description: Digital signature