Skip to content
This repository
Browse code

Merge pull request #747 from mattclements/npmrequire

Added NPM Requirement for older Node Versions
  • Loading branch information...
commit 2d939bd5ab347c2884d583ed7dc2e494fb713541 2 parents 6430f2a + 417ec37
Sindre Sorhus sindresorhus authored

Showing 1 changed file with 8 additions and 0 deletions. Show diff stats Hide diff stats

  1. +8 0 setup/install.sh
8 setup/install.sh
@@ -39,6 +39,7 @@ jpegturbofile=$(command -v jpegtran)
39 39 optipngfile=$(command -v optipng)
40 40 clangfile=$(command -v clang)
41 41 yeomanfile=$(command -v yeoman)
  42 + npmfile=$(command -v npm)
42 43
43 44 # Check if installed.
44 45 check_set(){
@@ -122,6 +123,9 @@ audit() {
122 123 jpegturbo=$(check_set $jpegturbofile)
123 124 optipng=$(check_set $optipngfile)
124 125 yeoman=$(check_set $yeomanfile)
  126 +
  127 + # node npm test
  128 + npm=$(check_set $npmfile)
125 129
126 130 # display results
127 131 #
@@ -143,6 +147,7 @@ audit() {
143 147
144 148 [ "$git" -eq 1 ] && happy_print "git" "smashing!"
145 149 [ "$node" -eq 1 ] && happy_print "NodeJS" "check."
  150 + [ "$npm" -eq 1 ] && happy_print "NodeJS NPM" "check."
146 151 [ "$ruby" -eq 1 ] && happy_print "ruby" "check."
147 152 [ "$gem" -eq 1 ] && happy_print "RubyGems" "check."
148 153 [ "$compass" -eq 1 ] && happy_print "Compass" "check."
@@ -173,6 +178,9 @@ audit() {
173 178 [ "$node" -eq 0 ] && \
174 179 sad_print "NodeJS" "" && \
175 180 desc_print "I recommend you grab a fresh NodeJS install (>= 0.8.x) from http://nodejs.org/download/ "
  181 + [ "$npm" -eq 0 ] && \
  182 + sad_print "NPM" "" && \
  183 + desc_print "I recommend you grab a fresh NodeJS install (>= 0.8.x) from http://nodejs.org/download/ as NPM Package manager is missing "
176 184 [ "$ruby" -eq 0 ] && \
177 185 sad_print "ruby" "" && \
178 186 desc_print "Check your ruby version is adequate with" "ruby -v" "(>= 1.8.7 required) and install http://www.ruby-lang.org/en/downloads/"

0 comments on commit 2d939bd

Please sign in to comment.
Something went wrong with that request. Please try again.