diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index ac75f0b6c8df10cd27ba475ee46497e425231b41..38df26d8d85d044290c680095dd88697a9a2b895 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -16,14 +16,21 @@ test: - yarn install - yarn run test -linting: - stage: test - allow_failure: true +publish: + stage: deploy + only: + refs: + - deploy + - master script: - - cd toolkit-showcase + # https://www.npmjs.com/settings/dbp-deploy/tokens + # NPM_TOKEN needs to be a "Publish" token with 2FA disabled! + # "Automation" tokens don't work with lerna (even if they would work with "npm publish") + - echo '//registry.npmjs.org/:_authToken=${NPM_TOKEN}' > ~/.npmrc + - yarn config set cache-folder "$CI_PROJECT_DIR/_yarn_cache" - yarn install - - yarn run lint - + - yarn run build + - yarn run publish .deploy_defaults: &deploy_defaults except: