Skip to content

Commit

Permalink
add deploy scripts
Browse files Browse the repository at this point in the history
  • Loading branch information
Christopher committed Jun 26, 2016
1 parent 15d6144 commit ffd59a4
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 0 deletions.
17 changes: 17 additions & 0 deletions deploy/after_push
@@ -0,0 +1,17 @@
#!/usr/bin/env bash
set -e
oldrev=$1
newrev=$2

run() {
[ -x $1 ] && $1 $oldrev $newrev
}

echo files changed: $(git diff $oldrev $newrev --diff-filter=ACDMR --name-only | wc -l)

umask 002

git submodule sync && git submodule update --init --recursive

run deploy/before_restart
run deploy/restart && run deploy/after_restart
1 change: 1 addition & 0 deletions deploy/before_restart
@@ -0,0 +1 @@
#!/bin/bash
7 changes: 7 additions & 0 deletions deploy/restart
@@ -0,0 +1,7 @@
#!/bin/bash

export PATH="$HOME/.rbenv/bin:$PATH"
eval "$(rbenv init -)"

bin/stop
bin/start

0 comments on commit ffd59a4

Please sign in to comment.