Last active
December 16, 2015 05:18
-
-
Save bhyde/5383182 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# 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