The JavaScript Database, for Node.js, nw.js, electron and the browser
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
nedb/.gitlab-ci.yml

40 lines
911 B

4 years ago
stages:
- lint
4 years ago
- test
- test-browser
4 years ago
- deploy
image: node:14
before_script:
- echo "//registry.npmjs.org/:_authToken=${NPM_REGISTRY_TOKEN}" > .npmrc
- echo "@seald-io:registry=https://registry.npmjs.org/" >> .npmrc
- echo "@seald-io:always-auth=true" >> .npmrc
4 years ago
- npm ci --cache .npm --prefer-offline
cache:
key: "nedb" # universal cache
paths:
- .npm/
lint:
stage: lint
script: npm run lint
4 years ago
test:
stage: test
script: npm run test
test-browser:
image: nexus-docker.tardis.seald.io/seald/docker-browser-testing:CHROME_88
stage: test-browser
script: npm run test:browser
4 years ago
deploy:
stage: deploy
script:
- if (npx semver $CI_COMMIT_TAG --range '>0.0.0'); then NPM_TAG=latest; else NPM_TAG=beta; fi; # Using the fact that semver by default considers that pre-releases do not respect stable ranges
- npm publish --tag=$NPM_TAG --access public
4 years ago
only:
- tags