What are the different methods available to run a shell
script?

Answer Posted / keerthi

3 ways

1. sh scriptname.sh

2. If the script has execute permission -

./script.sh


3. If the script has execute permission and is
stored in the directory listed in PATH ----

script.sh or .script.sh

Is This Answer Correct ?    13 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What lives in a shell?

537


What is the difference between bash and shell?

641


Explain about echo command?

622


How does path variable work?

543


Explain about non-login shell files?

690






How to debug the problems encountered in the shell script/program?

626


How do I start a shell script?

570


What exactly is a shell?

600


What is the significance of $#?

585


Which scripting language is best for automation?

528


What are the zombie processes?

563


What is the difference between scripting and coding?

533


What is a program shell?

568


How do I open the shell prompt?

571


What is a scripting language simple definition?

554