The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > Top Forums > Shell Programming and Scripting
Google UNIX.COM


Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts here.

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
convert unix script to perl gholdbhurg Shell Programming and Scripting 2 03-25-2008 10:42 AM
How to convert this linux command to Unix AIX? chris13work UNIX for Dummies Questions & Answers 1 11-20-2007 03:56 AM
grepping the output of a command in an if statement hcclnoodles Shell Programming and Scripting 3 06-29-2007 04:00 AM
awk command for INSERT statement nattynatty Shell Programming and Scripting 4 05-10-2002 11:11 AM
convert dwg to ps in Linux/Unix shell Jonny5000 UNIX for Dummies Questions & Answers 1 07-25-2001 10:22 AM

Reply
 
Submit Tools LinkBack Thread Tools Search this Thread Display Modes
  #1  
Old 05-20-2008
Registered User
 

Join Date: Feb 2008
Posts: 13
How to convert unix command into Awk statement

Hi all,

How can i use the below unix command in AWK . Can any one please suggest me how i can use.

sed -e "s/which first.sh/which \$0/g" $shell > $shell.sal

where $0=current program name(say current.sh)
$shell=second.sh
Reply With Quote
Forum Sponsor
  #2  
Old 05-20-2008
era era is offline
Herder of Useless Cats
 

Join Date: Mar 2008
Location: /there/is/only/bin/sh
Posts: 3,650
Code:
awk "{ gsub (\"which first\.sh\", \"which $0\") } 1" $shell >$shell.sai
Reply With Quote
Google The UNIX and Linux Forums
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes




All times are GMT -7. The time now is 11:10 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