Skip to content

Instantly share code, notes, and snippets.

@zph
Created June 13, 2014 14:27
Show Gist options
  • Select an option

  • Save zph/15e6181124a3c6e5fa44 to your computer and use it in GitHub Desktop.

Select an option

Save zph/15e6181124a3c6e5fa44 to your computer and use it in GitHub Desktop.
post-receive hook
#!/usr/bin/env bash
staging="blog.xargs.io.staging"
source $HOME/$staging/.envrc
GIT_WORK_TREE=$HOME/$staging/ git checkout -f
cd $HOME/$staging && \
bundle install && \
bundle exec rake gen_deploy
@zph

zph commented Jun 13, 2014

Copy link
Copy Markdown
Author

I followed this blog post for setting up my post-receive hook and deploying it to S3: http://weblog.masukomi.org/2011/12/19/serving-octopress-from-a-self-hosted-git-repository

Might help you get past that pathing hurdle.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment