image: registry.gitlab.com/openstapps/projectmanagement/node

stages:
  - test
  - publish

prettier config file:
  stage: test
  script:
    - npm test

package:
  tags:
    - secrecy
  stage: publish
  script:
    - echo "//registry.npmjs.org/:_authToken=$NPM_AUTH_TOKEN" > ~/.npmrc
    - npm publish --access=public
  only:
    - /^v[0-9]+\.[0-9]+\.[0-9]+$/
