I have a bash script like:
#!/bin/bash echo Hello world!
How do I execute this in Terminal?
You could do: sh scriptname.sh
sh scriptname.sh
And yet one more way
. /path/to/script
What is the meaning of the dot?
Change your directory to where script is located by using cd command
Then type
bash program-name.sh