variables: NPMPATH: "node_modules/.bin" stages: - build - deploy - clean_after_deploy Npm, Bower, Grunt: script: - npm install - $NPMPATH/bower install - $NPMPATH/grunt tags: except: - tags stage: build artifacts: paths: - dist/ - info/ - resources/ - index.html - manifest.appcache staging: stage: deploy script: deploy.sh environment: staging only: - develop variables: ENVIRON: staging production: stage: deploy script: deploy.sh environment: production only: - master variables: ENVIRON: production clean: stage: clean_after_deploy script: - rm -r node_modules - rm -r bower_components when: always