![]() |
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.
|
|
google unix.com
|
|||||||
| Forums | Register | Forum Rules | Links | Albums | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| 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 |
| A basic question of FOR loop | er_ashu | UNIX for Dummies Questions & Answers | 3 | 09-28-2007 10:41 AM |
| oracle and loop question | pavan_test | UNIX for Dummies Questions & Answers | 4 | 09-28-2006 11:23 PM |
| Simple while loop question | Brokeback | Shell Programming and Scripting | 3 | 07-21-2006 09:04 AM |
| foreach loop question | clipski | UNIX for Dummies Questions & Answers | 7 | 12-22-2005 01:28 PM |
| Loop question | strike | Shell Programming and Scripting | 18 | 04-13-2005 10:24 AM |
![]() |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
||||
|
while loop question
while [ $dev_num ]
do print What is the next device number to be added to $dgroup? print Press \<Enter\> if there are no more devices to be added. read dev_num export dev_num symld -g $dgroup -sid $sname add dev $dev_num done In this while loop, how do I stop it from running the final command if <Enter> is pressed? Currently, if a user presses <enter> it will still run symld -g $dgroup -sid $sname add dev I’m not sure how to skip this command if a user just presses <Enter> Thanks Edit: Forgot to mention this is the ksh |
|
|||||
|
Quote:
|
![]() |
| Bookmarks |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|