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 and shell scripting languages here.

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
awk arguments karthikn7974 Shell Programming and Scripting 6 05-07-2008 01:34 AM
if statement - how can I do 2 arguments? Darklight Shell Programming and Scripting 6 04-16-2008 10:28 AM
Arguments iago UNIX for Dummies Questions & Answers 1 08-24-2007 11:50 AM
Securing arguments SolidSnake Shell Programming and Scripting 0 05-21-2004 11:44 AM
passing arguments jpprial UNIX for Dummies Questions & Answers 4 04-03-2001 12:13 PM

 
English Japanese Spanish French German Portuguese Italian Dutch Swedish Russian Norwegian Hungarian Hebrew Danish Bulgarian Greek Powered by Powered by Google
 
LinkBack Thread Tools Search this Thread Rate Thread Display Modes
Prev Previous Post   Next Post Next
  #1 (permalink)  
Old 06-28-2002
homefp homefp is offline
Registered User
  
 

Join Date: Apr 2002
Posts: 20
several arguments together

Hello guys,

you may help me on this :

I want to search thru many files if a sentence or a string exists and printout the lines where this is present by calling a script like :

loc "arg1 arg2 arg3 arg4"
where arg1 arg2 arg3 arg4 would be in fact the sentence separated with blanks...

In my loc script, I would have to count the number of arguments and store them as a sentence into one single variable i guess, like :
sentence=`arg1 arg2 arg3 arg4`

But, as arguments number is undefined, how can i insure this to work in any case ?

Any idea ?
Thanks,
homefp
 

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes Rate This Thread
Rate This Thread:

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 On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On




All times are GMT -4. The time now is 11:39 AM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited. Language Translations Powered by .
vBCredits v1.4 Copyright ©2007 - 2008, PixelFX Studios
The UNIX and Linux Forums Content Copyright ©1993-2009. All Rights Reserved.Ad Management by RedTyger

Content Relevant URLs by vBSEO 3.2.0