Skip to content

Commit

Permalink
modify npm check method
Browse files Browse the repository at this point in the history
In previous versions of node.js, default output is 0, in latest version default output is 1. Use `npm version` to check whether npm is correctly installed.
  • Loading branch information
renkun-ken committed Jul 30, 2014
1 parent 4b783da commit ebb55a0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion R/checkForGitbook.R
Expand Up @@ -6,7 +6,7 @@
#' @param quiet logical indicating whether messages should be printed.
#' @export
checkForGitbook <- function(quiet=FALSE) {
if(system('npm', ignore.stdout=TRUE) != 0) {
if(system('npm version', ignore.stdout=TRUE) != 0) {
stop("Cannot find node.js. You can install it from http://nodejs.org/download/")
}
if(system('gitbook', ignore.stdout=TRUE) != 0) {
Expand Down

0 comments on commit ebb55a0

Please sign in to comment.