Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
#runs the working directory unit tests
NODE_ENV=test \
mocha --ignore-leaks $(shell find ./test -name \*test.js)
#deploys working directory
make test
make deploy-git
make deploy-servers
#deploys working to git deployment branch
status=$$(git status --porcelain) \
if test "x$${status}" = x
then \
git branch -f deployment \
git push origin deployment \
echo "Done deploying to git deployment branch." \
else \
git status \
echo "Error: cannot deploy. Working directory is dirty." \
exit 1 \
# for each server
# make deploy-server
# connect to this server with ssh
# check if app is already running
# stop the app on the server if already running
# set working directory to app folder
# update deployment git branch
# use git to move head to deployment branch
# start app again
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment