I have a small shell script thats gets triggerd by another script via ssh.
#!/bin/bash if [ -z $1 ] then echo "Missing DB Name!" exit 1 else PROJECT=$1 fi createdb -U postgres -T mytemplate -O myuser $PROJECT_dev
The problem is that the createdb statement doesent sees the $PROJECT variable. It's always empty when the script gets called.
I have no idea why.