Skip to content
This repository has been archived by the owner on Jul 23, 2021. It is now read-only.

Commit

Permalink
changelog and removing extraneous script runs
Browse files Browse the repository at this point in the history
  • Loading branch information
hunterloftis committed Mar 11, 2016
1 parent 649802e commit e2dd787
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 16 deletions.
5 changes: 5 additions & 0 deletions CHANGELOG.md
@@ -1,5 +1,10 @@
# Node.js Buildpack Changelog

## Latest

- Adds heroku-prebuild script
- Adds heroku-postbuild script

## v88 (2016-2-23)

- Retries all curl requests
Expand Down
16 changes: 0 additions & 16 deletions lib/dependencies.sh
Expand Up @@ -9,8 +9,6 @@ run_if_present() {

install_node_modules() {
local build_dir=${1:-}
local has_prebuild_script=${2:-}
local has_postbuild_script=${3:-}

if [ -e $build_dir/package.json ]; then
cd $build_dir
Expand All @@ -23,26 +21,16 @@ install_node_modules() {
echo "Installing node modules (package.json)"
fi
npm install --unsafe-perm --userconfig $build_dir/.npmrc 2>&1
if [ -n "$has_postbuild_script" ]; then
echo "Running postbuild script"
npm run heroku-postbuild
fi
else
echo "Skipping (no package.json)"
fi
}

rebuild_node_modules() {
local build_dir=${1:-}
local has_prebuild_script=${2:-}
local has_postbuild_script=${3:-}

if [ -e $build_dir/package.json ]; then
cd $build_dir
if [ -n "$has_prebuild_script" ]; then
echo "Running prebuild script"
npm run heroku-prebuild
fi
echo "Rebuilding any native modules"
npm rebuild 2>&1
if [ -e $build_dir/npm-shrinkwrap.json ]; then
Expand All @@ -51,10 +39,6 @@ rebuild_node_modules() {
echo "Installing any new modules (package.json)"
fi
npm install --unsafe-perm --userconfig $build_dir/.npmrc 2>&1
if [ -n "$has_postbuild_script" ]; then
echo "Running postbuild script"
npm run heroku-postbuild
fi
else
echo "Skipping (no package.json)"
fi
Expand Down

0 comments on commit e2dd787

Please sign in to comment.