Shell script menu for end user - difficult challenge 2
Hello,
I need to make shell script menu for my end users. There is like 100 scripts in system, and they need to run that scripts true one main script with user friendly menu.
Example, when user will run main menu script, it will get something like this on his screen:
_________________________________________________________
Please insert number of steps?
User: 3
Insert step 1?
User: script47.sh Insert parameter for step 1? ST I
Insert check return code for script1.sh?
100
Insert step 2?
User: script78.sh Insert parameter for step 2? ST ZS I
Insert check return code for script78.sh?
100
Insert step 3?
User: script34.sh Insert parameter for step 2? TI ZS Insert check return code for script34.sh?
100
_________________________ Check before running the scripts:
1. Step: script1.sh -- ST I - return code 0
2. Step: script78.sh -- ST ZS I- return code 1
3. Step: script34.sh -- TI ZS - return code 0 For continue insert yes
User: yes
**************************
Then script executing look like this
/app/test/script47.sh ST I
chk_rc_100
/app/test/script78.sh ST ZS I
chk_rc_100
/app/test/script34.sh TI ZS
chk_rc_100
_________________________________________________________
This is example of main script if you make it with fixed parameter, this is like some plan of executing, but i need to make menu so user can pick how many script will run and enter scripts name. Check return code is same for every case.
I get this solution from one forum member, but its not working
I have a menu option which will look as follows
Select a menu option
1.change password
2.login as root user
3.show system version
4.quit
Select> 1
please enter the new password: unix
reenter the new password: unix
press any key to enter
(then displays again the menu options to enter the... (4 Replies)
Hi All,
I have written a shell script that show menu driven option.
My requirement is that in the menu driven option i want to select multiple choice.
i.e
if i want to select 1 or 1,2 or 1,2,3 or 2,3 etc ....
Can some one help me in that
My script.
while true; do
echo " "
... (8 Replies)
I'm writing a shell script and have a problem with selection when I issue the command, is there a way to automatically choose a selection number one after a selection menue appear
Command
1-choice
2- choice
3-choice
Thanks
Sara (3 Replies)
I have tried searching the forum but i haven't found a solution for this.
I have a shell script that presents the users with menus. The menus branch out to sub menus. It is all hunky dory as long as i traverse forward. But if i am in a sub menu and return to the previous menu and choose any... (11 Replies)
Hi,
I need to have a shell script for the below need.
1. Menu with one heading and 4 options.
2. the heading and 4 options are taken from a file.
File entry
======
Heading1|option1|option2|option3|option4|
Heading2|option1|option2|option3|option4|
3. the user entries must be captured in... (9 Replies)
Hello,
I need to make shell script menu for my end users. There is like 100 scripts in system, and they need to run that scripts true one main script with user friendly menu.
Example, when user will run main menu script, it will get something like this on his screen:... (3 Replies)
hi guys, how would you do the following? I have a menu with 5 options in my shell script:
1. Run function 1 against files
2. Run function 2 against files
3. Run function 3 against files
4. Run function 4 against files
5. Run function 5 against files
I'd like to be able to run multiple... (10 Replies)
two tabulate files (A, B), each contents thousands and thousands lines with ids.
first find out contents with common ids in both A, B and print out into a file;
second find out contents with ids which only exist in file A and print out into a file. (4 Replies)
I am attempting to create a shell script with the following capaciblities:
1. Listed options to choice from
2. Use to perform awk statements
3. Print a report with the awk results
My questions are
1. How do I select more than one file for option #5 and #6
2. How to I create an... (11 Replies)