Unix/Linux Go Back    


Shell Programming and Scripting Unix shell scripting - KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and shell scripts and shell scripting languages here.

sed & awk

Shell Programming and Scripting


Tags
learn unix

Closed Linux or Unix Question    
 
Thread Tools Search this Thread Display Modes
    #1  
Old Unix and Linux 09-07-2008
kukuruku kukuruku is offline
Registered User
 
Join Date: Aug 2008
Last Activity: 5 May 2009, 3:31 AM EDT
Location: Moscow, Russia
Posts: 15
Thanks: 0
Thanked 0 Times in 0 Posts
sed & awk

Hi.
I'm going to learn scripting and i have the following topics on the list: sed, awk, shell scripting, perl.

My question is, whehter i should learn sed and awk? Aren't this tools outdated?
Although i see that GNU upgrade it's versions of these tools from time to time.

And, the next question. Would the "Sed & awk" book be useful for reading on the sed topic? It is 1997.

For awk i'm going to read Effective awk Programming by GNU.
Sponsored Links
    #2  
Old Unix and Linux 09-07-2008
era era is offline Forum Advisor  
Herder of Useless Cats (On Sabbatical)
 
Join Date: Mar 2008
Last Activity: 28 March 2011, 6:41 AM EDT
Location: /there/is/only/bin/sh
Posts: 3,653
Thanks: 0
Thanked 10 Times in 8 Posts
The sed & awk book is excellent for both. They are useful and stable tools which do not evolve much any more, but are still useful to have around. If you mean to be able to read and understand Unix shell scripts written by others, they are a must. Advanced sed scripting might not be all that useful to know if you are going to be learning awk and Perl anyway, but the basics (substitution, regex matching, maybe simple loops) are used a lot to make up for missing features in the shell.

PS I guess you know both books are available on-line for free?
http://books.google.com/books?hl=en&...result#PPP1,M1
http://www.gnu.org/software/gawk/manual/

Last edited by era; 09-07-2008 at 01:00 PM.. Reason: Links to online editions
Sponsored Links
    #3  
Old Unix and Linux 09-07-2008
nani_ynm's Unix or Linux Image
nani_ynm nani_ynm is offline
Registered User
 
Join Date: Nov 2005
Last Activity: 22 December 2013, 2:55 AM EST
Location: Bangalore
Posts: 13
Thanks: 0
Thanked 0 Times in 0 Posts
thanks for the links era...

Good qns be kukuruku...

My question is, whehter i should learn sed and awk? Aren't this tools outdated?
Although i see that GNU upgrade it's versions of these tools from time to time.

Can somebody ans for the above please...

- nani
    #4  
Old Unix and Linux 09-07-2008
ghostdog74 ghostdog74 is offline
Registered User
 
Join Date: Sep 2006
Last Activity: 28 January 2015, 8:30 AM EST
Posts: 2,669
Thanks: 0
Thanked 18 Times in 18 Posts
if you want to choose 1 between the 2 , then learn awk.
Sponsored Links
    #5  
Old Unix and Linux 09-08-2008
broli's Unix or Linux Image
broli broli is offline
Registered User
 
Join Date: Dec 2007
Last Activity: 23 July 2014, 5:32 PM EDT
Location: Argentina
Posts: 219
Thanks: 0
Thanked 0 Times in 0 Posts
Quote:
Originally Posted by nani_ynm View Post
thanks for the links era...

Good qns be kukuruku...

My question is, whehter i should learn sed and awk? Aren't this tools outdated?
Although i see that GNU upgrade it's versions of these tools from time to time.

Can somebody ans for the above please...

- nani
those tools where created a long time ago, they are old, not outdated !!
there still beeing updated.
they are used alot in linux system scripts
a huge part of the scripts around relay on those

so, is it worth it ? (and pardon the my french) hell yeah

their importance is more clear after you learn how many things they can do

how much in depth you learn depends on what you spect to accomplish
Sponsored Links
    #6  
Old Unix and Linux 09-08-2008
matrixmadhan matrixmadhan is offline Forum Advisor  
Technorati Master
 
Join Date: Mar 2005
Last Activity: 16 July 2015, 8:07 AM EDT
Location: classification algos
Posts: 3,206
Thanks: 19
Thanked 30 Times in 27 Posts
Quote:
Originally Posted by ghostdog74 View Post
if you want to choose 1 between the 2 , then learn awk.
I would suggest both are important assuming that perl is not in the choice list, had perl been there in the list it would do everything Linux

I feel its quite easier with sed to regex, information extraction etc.

Just my 2 cents Linux
Sponsored Links
    #7  
Old Unix and Linux 09-08-2008
Franklin52's Unix or Linux Image
Franklin52 Franklin52 is offline Forum Staff  
Moderator
 
Join Date: Feb 2007
Last Activity: 4 August 2015, 6:17 AM EDT
Location: The Netherlands
Posts: 7,731
Thanks: 129
Thanked 547 Times in 515 Posts
It depends on what you want to do with Unix/Linux but first off, try to master the system utilities: ls, cat, cmp, grep, etc. and learn to use an editor like vi(m). Then, master the shell, you can do a great deal of useful work with just the shell and the utilities.

Once you've learned how to write useful scripts in the shell, try to master utilities like sed and awk.
After that you can think about a program language and that depends on what you want to do.

Regards
Sponsored Links
Closed Linux or Unix Question

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes



All times are GMT -4. The time now is 10:20 PM.