The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > Top Forums > UNIX for Dummies Questions & Answers
Google UNIX.COM


UNIX for Dummies Questions & Answers If you're not sure where to post a UNIX or Linux question, post it here. All UNIX and Linux newbies welcome !!

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
Development Releases: Linux Mint 4.0 Beta "Fluxbox", 4.0 Alpha "Debian" iBot UNIX and Linux RSS News 0 01-04-2008 12:00 PM
Explain the line "mn_code=`env|grep "..mn"|awk -F"=" '{print $2}'`" Lokesha UNIX for Dummies Questions & Answers 4 12-19-2007 10:52 PM
Debian: doubt in "top" %CPU and "sar" output jaduks Linux 0 09-12-2007 05:05 AM
Sorting problem "sort -k 16,29 sample.txt > output.txt" ganapati Shell Programming and Scripting 3 08-01-2006 02:55 AM
No utpmx entry: you must exec "login" from lowest level "shell" peterpan UNIX for Dummies Questions & Answers 0 01-18-2006 01:15 AM

Reply
 
Submit Tools LinkBack Thread Tools Display Modes
  #1  
Old 07-12-2007
Registered User
 

Join Date: Jul 2006
Posts: 36
the operato < for redirect output "inverse"....

see this

cat < Files
return the cointent of Files

but

cat files

return the same result


WHI???


this command

lp -f """PRINTER" < cat files

not print the content of files

WHI ???

i not understand the use of <
Reply With Quote
Forum Sponsor
  #2  
Old 07-12-2007
Registered User
 

Join Date: Jan 2007
Posts: 2,965
every process has three default file descriptors open when it starts

0 - stdin
1 - stdout
2 - stderr

the ">" operator creates a file and attaches it to stdout
the ">>" opens a file for appending and attaches it to stdout
the "<" opens an existing file and attaches it to stdin
the "|" attaches the stdout of the preceding process to the stdin of the following

The program cat "concatenates" a list of files given as arguments to stdout, if no files are listed it simply reads from stdin and writes that to stdout.
Reply With Quote
Google The UNIX and Linux Forums
Reply

Thread Tools
Display Modes




All times are GMT -7. The time now is 02:01 PM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited.
The UNIX and Linux Forums Content Copyright ©1993-2008. All Rights Reserved.Ad Management by RedTyger Visit The Complex Event Processing Blog

Content Relevant URLs by vBSEO 3.2.0