LinuxQuestions.org
Visit the LQ Articles and Editorials section
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices

Reply
 
Search this Thread
Old 11-11-2003, 07:57 PM   #1
nro
Member
 
Registered: Oct 2003
Distribution: Mandrake 9
Posts: 46

Rep: Reputation: 15
Using commands to output to files, how is this done?


I know there are commands out there that can print a command output to a file. My expereince with this is very limited. I know of the command &< but what I want to know is, are there any more command like this? When using this command, how can I append the results to the end of a file?
Thanks
 
Old 11-11-2003, 08:00 PM   #2
jim mcnamara
Member
 
Registered: May 2002
Posts: 964

Rep: Reputation: 34
> creates and writes the file (redirection)
>> appends to the file (redirection)

Code:
ll -rt a* > filelist
ll -rt b* >> filelist
Makes a file with all of the file starting with letter "a", then
adds names of file that start with "b"
 
Old 11-11-2003, 08:04 PM   #3
slakmagik
Senior Member
 
Registered: Feb 2003
Distribution: Slackware
Posts: 4,113

Rep: Reputation: Disabled
More fun with redirection.
 
Old 11-11-2003, 08:38 PM   #4
nro
Member
 
Registered: Oct 2003
Distribution: Mandrake 9
Posts: 46

Original Poster
Rep: Reputation: 15
Those commands are fine and work great, thank you for that. But I'm looking for a consistant stream from the console(background) to the file. Know of a technique?
Thanks
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Linux commands - giving doubled output shinobi59 Red Hat 1 11-07-2005 06:43 PM
adding my own commands to rc files SizofreNICK Slackware 8 11-07-2004 02:30 AM
Need help with some commands to prune files... smeenge Linux - Software 2 05-21-2004 05:10 PM
Bash: How to concatenate the output of different commands? J_Szucs Programming 1 11-13-2003 07:43 AM
how to read the output of df -k and about logical volumes commands jdara1 Linux - Software 3 05-23-2003 12:22 PM


All times are GMT -5. The time now is 06:22 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration