diff --git a/npm-publish.yml b/npm-publish.yml new file mode 100644 index 0000000..9938f6a --- /dev/null +++ b/npm-publish.yml @@ -0,0 +1,33 @@ +# This workflow will run tests using node and then publish a package to GitHub Packages when a release is created +# For more information see: https://help.github.com/actions/language-and-framework-guides/publishing-nodejs-packages + +name: Node.js Package + +on: + release: + types: [created] + +jobs: + build: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - uses: actions/setup-node@v2 + with: + node-version: 14 + - run: npm ci + - run: npm test + + publish-npm: + needs: build + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - uses: actions/setup-node@v2 + with: + node-version: 14 + registry-url: https://registry.npmjs.org/ + - run: npm ci + - run: npm publish --access public + env: + NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}} diff --git a/package-lock.json b/package-lock.json index a3db8fd..b5a30d6 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,6 +1,6 @@ { - "name": "biovalidator", - "version": "1.9.0", + "name": "@ebi-ait/biovalidator", + "version": "1.10.1", "lockfileVersion": 1, "requires": true, "dependencies": { diff --git a/package.json b/package.json index c6a603d..082e442 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { - "name": "biovalidator", - "version": "1.9.1", + "name": "@ebi-ait/biovalidator", + "version": "1.10.1", "description": "A nodejs JSON schema validator service. Extended from Ajv to include ontology validation.", "main": "src/server.js", "repository": "https://github.com/elixir-europe/biovalidator.git",