diff --git a/README.md b/README.md new file mode 100644 index 00000000..402e30fd --- /dev/null +++ b/README.md @@ -0,0 +1,10 @@ +# Hello Language Pack + +The Hello Language Pack will look for a file named `hello.txt` in the app root and +display its contents during push. + +## Usage + +Add this language pack to your `LANGUAGE_PACK_URL`. + + heroku config:add LANGUAGE_PACK_URL="http://github.com/heroku/language-pack-hello.git" diff --git a/bin/compile b/bin/compile new file mode 100755 index 00000000..2efdda1d --- /dev/null +++ b/bin/compile @@ -0,0 +1,18 @@ + #!/bin/sh + + indent() { + sed -u 's/^/ /' + } + + echo "-----> Found a hello.txt" + + # if hello.txt has contents, display them (indented to align) + # otherwise error + + if [ ! -s $1/hello.txt ]; then + echo "hello.txt was empty" | indent + exit 1 + else + echo "hello.txt is not empty, here are the contents" | indent + cat $1/hello.txt | indent + fi diff --git a/bin/detect b/bin/detect new file mode 100755 index 00000000..9aa551e3 --- /dev/null +++ b/bin/detect @@ -0,0 +1,9 @@ +#!/bin/sh + +# this pack is valid for apps with a hello.txt in the root +if [ -f $1/hello.txt ]; then + echo "HelloFramework" + exit 0 +else + exit 1 +fi diff --git a/bin/release b/bin/release new file mode 100755 index 00000000..b950604e --- /dev/null +++ b/bin/release @@ -0,0 +1,11 @@ +#!/bin/sh + +cat << EOF +--- +addons: + - shared-database:5mb +config_vars: + PATH: bin:/usr/bin:/bin +default_process_types: + hello: cat hello.txt +EOF