Mailinglist Archive: opensuse (4631 mails)
| < Previous | Next > |
[opensuse] Bash script which read command option
- From: jan kalcic <jandot@xxxxxxxxxxxxxx>
- Date: Thu, 18 Jan 2007 15:34:17 +0100
- Message-id: <45AF8569.6020208@xxxxxxxxx>
Hi People,
How can I have my bash script read the option I pass in command line?
Let's suppose the script looks like this:
#!/bin/bash
ping -c "?" 192.168.1.1
I want to have that number of count passed by command line when I launch
the script. For example: # ./script 5 would execute ping -c 192.168.1.1
TIA,
Jan
--
To unsubscribe, e-mail: opensuse+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: opensuse+help@xxxxxxxxxxxx
How can I have my bash script read the option I pass in command line?
Let's suppose the script looks like this:
#!/bin/bash
ping -c "?" 192.168.1.1
I want to have that number of count passed by command line when I launch
the script. For example: # ./script 5 would execute ping -c 192.168.1.1
TIA,
Jan
--
To unsubscribe, e-mail: opensuse+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: opensuse+help@xxxxxxxxxxxx
| < Previous | Next > |