#!/bin/bash set -e set -x env=`app conf get env.FIKEN_ENVIRONMENT` props="current/etc/$env/environment.properties" password=`sed -n 's,^database.password=\(.*\),\1,p' $props` app conf set app.version $1 app upgrade sed 's,^\(database.password\)=.*,\1=$password,' $props > x mv x $props echo "Type app restart when ready to start new version."