Scripting Classroomnotes 30/Oct/2022


  • Command is an executable written in any language.
  • An executable has execute permissions for owner or group or other(RWX)
  • To run the shell script
bash <path-to-script>.sh
# if we change permissions to execute

* Now commands like ls, ping etc are executed without complete file path
* When you type any command in linux or windows systems it searches for the executable in certain folders. These folders are listed in environmental variable called PATH
* Linux: folder paths seperated by colon
* Windows: folder paths seperated by semicolon
* Linux Path:


* Now lets make our work from anywhere
* copy the into any folder which is already part of path variable.
* We can also copy the script to new location and remove the extension
* To see all the environmental variables, possibilities are
* set
* declare
* printenv
* Next Steps:
* Adding folders of our choice to PATH
* Every command generally takes arguments

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

About continuous learner

devops & cloud enthusiastic learner