Merge pull request #6 from chiraag918/development #7
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Publish Package | |
on: | |
push: | |
branches: | |
- main | |
jobs: | |
build: | |
name: Build and Publish | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v3 | |
- name: Use Node.js 18.x | |
uses: actions/setup-node@v3 | |
with: | |
node-version: 18.x | |
registry-url: https://npm.pkg.github.com | |
scope: "@chiraag918" | |
always-auth: true | |
- name: Install dependencies | |
run: npm i | |
env: | |
NODE_AUTH_TOKEN: ${{ secrets.PUBLISH_TOKEN }} | |
- name: Build library | |
run: npm run build | |
- name: Publish to GitHub Packages | |
run: npm publish | |
env: | |
NODE_AUTH_TOKEN: ${{ secrets.PUBLISH_TOKEN }} |