Skip to content

Instantly share code, notes, and snippets.

@bhyde
Last active December 16, 2015 05:18
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save bhyde/5383182 to your computer and use it in GitHub Desktop.
Save bhyde/5383182 to your computer and use it in GitHub Desktop.
# Quick start script for heroku-buildpack-ccl64-example1
# Pipe this into bash.
function LOG(){
cat <<EOF
=== LOG: $* ===
EOF
}
unset F
function FAIL(){
echo "Error: $*"
F=1
}
function GO(){
[ -z $( which curl ) ] && FAIL "install requires curl."
[ -z $( which git ) ] && FAIL "heroku usage requires that git is installed."
[ -z $( which heroku ) ] && FAIL "heroku usage requires that the heroku tools are installed."
[ -d heroku-buildpack-ccl64-example1 ] && FAIL "heroku-buildpack-ccl64-example1 is installed here."
[ -z $F ] || exit 1
LOG '1. Fetch the examples source using git clone into heroku-buildpack-ccl64-example1.'
git clone git://github.com/bhyde/heroku-buildpack-ccl64-example1.git
LOG '2. Create an heroku application to be built by heroku-buildpack-ccl64.'
cd heroku-buildpack-ccl64-example1
heroku create -s cedar --buildpack https://github.com/bhyde/heroku-buildpack-ccl64.git
LOG "3. Push the application to heroku, trigger the buildapp into building the application's slug"
git push heroku master --verbose
LOG "4. Visit the application's site in your web browser, but wait a moment first."
echo 'but pause a moment to give things time to settle in at heroku'
sleep 4
heroku open
LOG "All done, cd into heroku-buildpack-ccl64-example1 to see the example's sources"
}
GO
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment