Download your favorite Linux distribution at LQ ISO.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
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!


  Search this Thread
Old 11-27-2005, 10:01 PM   #1
LQ Newbie
Registered: Sep 2005
Posts: 12

Rep: Reputation: 0
A question about BASH

Hi everyone:

I want to see the header of mails in my mailbox on Redhat Linux. So I wrote the following awkward shell :

mail < mail.input | awk '/U / {print}'

The content of file "mail.input" is just :


How could I do this without the file "mail.input"?

Thanks for your attention and look forward to your replay.
Old 11-27-2005, 10:11 PM   #2
Registered: Sep 2004
Location: Old York, North Yorks.
Distribution: Debian 7 (mainly)
Posts: 653

Rep: Reputation: 88
Hi, operand.

You could try:

echo "quit" | mail | awk '/U / {print}'

Old 11-27-2005, 10:49 PM   #3
LQ Newbie
Registered: Sep 2005
Posts: 12

Original Poster
Rep: Reputation: 0
Originally posted by Robhogg
Hi, operand.

You could try:

echo "quit" | mail | awk '/U / {print}'

Hi rob:

That works. Thanks a lot. ^_^ .



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
BASH question robscott Linux - Software 3 11-23-2005 10:39 AM
Bash question lnxduck Programming 3 09-30-2005 09:50 AM
bash question? shanenin Linux - Software 1 11-26-2004 01:22 PM
BASH question tpe Linux - Software 6 11-17-2004 09:59 PM
little bash question gplacek Linux - General 2 09-01-2004 01:10 PM

All times are GMT -5. The time now is 09:52 PM.

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