How to group the commands in shell scripting?

Answers were Sorted based on User's Feedback



How to group the commands in shell scripting?..

Answer / linuxdemon(vjsujay@gmail.com)

(unix cmd 1; unix cmd2)

eg:

ubuntu@ubuntu:~$ (w > fname ; wc -l fname)
10 fname
ubuntu@ubuntu:~$

Is This Answer Correct ?    10 Yes 2 No

How to group the commands in shell scripting?..

Answer / tony

The command separator is ;

So, just run:

$ echo Let me wait some time ; sleep 10 ; echo Yes, that is OK

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More Shell Script Interview Questions

What is the syntax of while loop in shell scripting?

0 Answers  


What is bash command used for?

0 Answers  


What is a batch file used for?

0 Answers  


What does echo mean in scripting?

0 Answers  


What are the different kinds of loops available in shell script?

3 Answers  


What is the use of a shebang line?

0 Answers  


What is scripting autism?

0 Answers  


What is the meaning of $1 in shell script?

0 Answers  


How Connect to a Database in Shell Programming?

4 Answers   Syntel,


RAM one table colums a1,a2,a3,a4 respective values 2,4,7,8 KRISH one table colums a1,a2,a3,a4 respective values 3,4,6,9 IN RAM & KRISH a4 column if comparing values RAM A4 - KRISH A4 ( 8-9 =1 THEN print 5 or (RAM) a4 value 10 KRISH a4 values 2 then 10 -2 =8 print 5*8=40 or diff 5 print same

1 Answers   Tech Mahindra,


State the advantages of shell scripting?

0 Answers  


How to modify the PATH variable and make it executable?

3 Answers   Mind Tree,


Categories