how to run a sh file on the command line code example Example 1: how to run a .sh file ./yourscript.sh Example 2: run sh file sh yourfile.sh