add variable to sh script code example Example: sh declare variable #!/bin/sh MY_MESSAGE="Hello World" echo $MY_MESSAGE