Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in
Toggle navigation
H
heroku-buildpack-nodejs
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
JIRA
JIRA
Merge Requests
0
Merge Requests
0
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Python-Dev
heroku-buildpack-nodejs
Commits
bdab3378
Commit
bdab3378
authored
Dec 09, 2013
by
zeke
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
only prune when node_modules directory is restored from cache. Fixes #75
parent
e6703624
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
3 deletions
+3
-3
compile
bin/compile
+3
-3
No files found.
bin/compile
View file @
bdab3378
...
@@ -62,15 +62,15 @@ if test -d $build_dir/node_modules; then
...
@@ -62,15 +62,15 @@ if test -d $build_dir/node_modules; then
elif
test
-d
$cache_dir
/node_modules
;
then
elif
test
-d
$cache_dir
/node_modules
;
then
status
"Restoring node_modules directory from cache"
status
"Restoring node_modules directory from cache"
cp
-r
$cache_dir
/node_modules
$build_dir
/
cp
-r
$cache_dir
/node_modules
$build_dir
/
status
"Pruning cached dependencies not specified in package.json"
npm prune 2>&1 | indent
fi
fi
# Make npm output to STDOUT instead of its default STDERR
# Make npm output to STDOUT instead of its default STDERR
status
"Installing dependencies"
status
"Installing dependencies"
npm
install
--userconfig
$build_dir
/.npmrc
--production
2>&1 | indent
npm
install
--userconfig
$build_dir
/.npmrc
--production
2>&1 | indent
status
"Pruning dependencies not specified in package.json"
npm prune 2>&1 | indent
status
"Caching node_modules directory for future builds"
status
"Caching node_modules directory for future builds"
rm
-rf
$cache_dir
rm
-rf
$cache_dir
mkdir
-p
$cache_dir
mkdir
-p
$cache_dir
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment