Script loop question
Oliver Marshall
Oliver.Marshall at g2support.com
Thu Nov 12 08:59:43 UTC 2009
Hi chaps,
Can someone point me in the direction of an example that will help me do this?
I have a script that takes an argument (a file name) and performs actions on that file. I want to mod the script so that i can pass, as arguments, multiple filenames and have the script perform the same set of commands on each file in turn, like this;
./filename.sh file1 file2 file3
etc.
I guess it's bringing the two parts of the loop and the arguments together to loop through each argument in turn, but that's where I get stuck.
Thanks
Olly
--
G2 Support
Network Support : Online Backups : Server Management
[cid:image001.jpg at 01CA6376.79EA9D30]
Tel: 0845 307 3443
Email: oliver.marshall at g2support.com<mailto:oliver.marshall at g2support.com>
Web: http://www.g2support.com<http://www.g2support.com/>
Twitter: g2support<http://twitter.com/home?status=@g2support>
Newsletter: http://www.g2support.com/newsletter
Mail: 2nd Floor, 130a Western Rd, Brighton, Sussex, BN12LA
G2 Support LLP is registered at Mill House, 103 Holmes Avenue, HOVE
BN3 7LE. Our registered company number is OC316341.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.ubuntu.com/archives/ubuntu-users/attachments/20091112/4f962ac1/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image001.jpg
Type: image/jpeg
Size: 1969 bytes
Desc: image001.jpg
URL: <https://lists.ubuntu.com/archives/ubuntu-users/attachments/20091112/4f962ac1/attachment.jpg>
More information about the ubuntu-users
mailing list