Creating files

Cameron Simpson cs at zip.com.au
Thu Apr 20 21:17:05 UTC 2006


On 20Apr2006 15:26, Anthony Messina <amessina at messinet.com> wrote:
| kevin.kempter at dataintellect.com wrote:
| > Likewise you can re-direct nothing to a filename like this (without the double 
| > quotes of course):
| > 
| > "> newfile"
| 
| kevin, that is the most phenomenal thing i've seen since i've started
| using linux.  i laughed when i read it -  because it's a great way to do
| it!  although i wasn't the one asking the question, that's a great way
| to think outside the box.

Heh. We used to operate tape drives similarly, disparaging the use of
the mt command:

	< /dev/st0	# rewind
	< /dev/nst0	# fast forward one file

As mentioned:

	> filename	# truncate file, creating if necessary
	>> filename	# create file if necessary, but to not destroy data

Cheers,
-- 
Cameron Simpson <cs at zip.com.au> DoD#743
http://www.cskk.ezoshosting.com/cs/

Fear not the evil men do in the name of evil, but heaven protect us from the
evil men do in the name of good.




More information about the fedora-list mailing list