install gulp globally

This commit is contained in:
Joan Sanchez 2018-10-24 14:59:49 +02:00
parent 6493b05f2b
commit f8d11c01b8
1 changed files with 1 additions and 4 deletions

5
Jenkinsfile vendored
View File

@ -17,10 +17,6 @@ switch (env.BRANCH_NAME) {
} }
node { node {
//env.NODEJS_HOME = "${tool 'node-8.12.0'}"
// on linux / mac
//env.PATH="${env.NODEJS_HOME}/bin:${env.PATH}"
stage ('Print environment variables') { stage ('Print environment variables') {
echo "Branch ${env.BRANCH_NAME}, build number ${env.BUILD_NUMBER}, environment ${env.NODE_ENV}" echo "Branch ${env.BRANCH_NAME}, build number ${env.BUILD_NUMBER}, environment ${env.NODE_ENV}"
} }
@ -29,6 +25,7 @@ node {
} }
stage ('Install Node dependencies') { stage ('Install Node dependencies') {
nodejs('node-8.12.0') { nodejs('node-8.12.0') {
sh "npm install gulp -g"
sh "npm install --only=prod" sh "npm install --only=prod"
sh "npm install --only=dev" sh "npm install --only=dev"
sh "gulp install" sh "gulp install"