-
Tom Käsler authored7b5180c5
This GitLab CI configuration is valid.
Learn more
Forked from an inaccessible project.
variables:
BUILD_DIR: dist
stages:
- codestyle
- test
- build
- review
- deploy
cache:
key: ${CI_COMMIT_REF_SLUG}
paths:
- node_modules/
tslint:
stage: codestyle
tags:
- nodejs
allow_failure: false
dependencies: []
script:
- echo "{}" > package.json
- npm install tslint-angular
- npm install tslint-eslint-rules
- npm install @angular/compiler
- npm install @angular/core
- npm install typescript
- npm install rxjs
- node_modules/tslint/bin/tslint -p ./tsconfig.json -c ./tslint.json --project
unit_tests:
stage: test
tags:
- nodejs
allow_failure: false
dependencies: []
variables:
CHROME_BIN: /usr/bin/google-chrome
script:
- npm install
- npm test
ngbuild:
stage: build
tags:
- angular
allow_failure: false
dependencies: []
script:
- npm install -g @angular/cli
- npm install
- ng build --prod --aot=false --build-optimizer=false
artifacts:
paths:
- "$BUILD_DIR"
#review:
# stage: review
# script:
# - rsync -av --delete "$BUILD_DIR" /srv/nginx/pages/$CI_BUILD_REF_SLUG
# environment:
# name: review/$CI_BUILD_REF_NAME
# url: http://$CI_BUILD_REF_SLUG.$SERVER_URL
# on_stop: stop_review
# only:
# - branches
# except:
# - master
# tags: