Results 1 to 2 of 2
Hi all,
I am trying to do a for each script but cant seem to get it right, can someone point me in the correct direction?
This is what i ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
- 05-04-2006 #1Just Joined!
- Join Date
- May 2006
- Posts
- 4
Script Help
Hi all,
I am trying to do a for each script but cant seem to get it right, can someone point me in the correct direction?
This is what i have so far.
if
grep UPDATED=Y *.lib
then
grep UPDATED=Y -B 8 *.lib | grep NAME= > newsigs`date '+%d%m%y'`cat newsigs`date '+%d%m%y'` | mail -s "NEW SIGS" XXXX@XXX.comrm -f newsigs`date '+%d%m%y'`
else
cat No_New_Sigs | mail -s "NO NEW SIGS" XXXX@XXX.comfi
now what i want to achieve is after the 'then' i want a for each command that has the following commands in:
grep UPDATED=Y -B 8 *.lib | grep NAME= > newsigs`date '+%d%m%y'`
grep UPDATED=Y -B 8 *.lib | grep EVENTGROUP= > newsigs`date '+%d%m%y'`
Any help is much appreciated
Nick T
- 05-07-2006 #2
I'm not sure what you are trying to do... and I assume you want a BASH script. I'd be glad to help but you need to explain, step by step, what you are trying to do.
Avatar from xkcd.com, a hilarious computer related webcomic.


Reply With Quote
