Skip to content

Commit

Permalink
chore: new deploy script
Browse files Browse the repository at this point in the history
  • Loading branch information
joamag committed Aug 6, 2024
1 parent c38ad91 commit 351c87a
Showing 1 changed file with 33 additions and 0 deletions.
33 changes: 33 additions & 0 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
name: Deploy Workflow
on:
push:
tags:
- "*"
jobs:
build:
name: Deploy
timeout-minutes: 10
strategy:
matrix:
node-version: [14]
runs-on: ubuntu-latest
container: node:${{ matrix.node-version }}-buster
steps:
- name: Checkout code from repository
uses: actions/checkout@v4
- name: Print Node.js information
run: node --version
- name: Install package
run: npm install
- name: Install package (development)
run: npm install --only=dev
- name: Verify Javascript code linting
run: npm run lint
- name: Run unit tests
run: npm test
- name: Deploy package to NPM
run: |
echo "//registry.npmjs.org/:_authToken=${NPM_TOKEN}" > ~/.npmrc
npm publish
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}

0 comments on commit 351c87a

Please sign in to comment.