Skip to content

Commit

Permalink
test
Browse files Browse the repository at this point in the history
  • Loading branch information
priyagupta108 committed Feb 5, 2024
1 parent d8d0f90 commit c1a0271
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 16 deletions.
40 changes: 25 additions & 15 deletions .github/workflows/npm-publish-github-packages.yml
Original file line number Diff line number Diff line change
@@ -1,22 +1,32 @@
name: Node.js CI
name: Node.js Package

on:
push:
branches: [ yarn-test ]

branches:
- yarn-test

jobs:
build:
publish-gpr:
runs-on: ubuntu-latest

permissions:
contents: read
packages: write
steps:
- uses: actions/checkout@v4
- uses: dmitry-shibanov/setup-node@v-dmshib/fix-arm64-for-windows
with:
node-version: '20'
cache: 'yarn'
- run: yarn install
- run: yarn test
- run: yarn publish
env:
NODE_AUTH_TOKEN: ${{secrets.GITHUB_TOKEN}}
- uses: actions/checkout@v4
- run: corepack enable
- uses: dmitry-shibanov/setup-node@v-dmshib/fix-arm64-for-windows
with:
node-version: 20
cache: 'yarn'
registry-url: https://npm.pkg.github.com
scope: '@priyagupta108'
- name: Prepare NPM credentials
run: |
echo npmAuthToken: "$NODE_AUTH_TOKEN" >> ./.yarnrc.yml
env:
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- run: yarn npm publish
env:
NODE_AUTH_TOKEN: ${{secrets.GITHUB_TOKEN}}

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@priyagupta108/sample-node",
"version": "1.0.4",
"version": "1.0.5",
"description": "sample-node application",
"main": "index.js",
"scripts": {
Expand Down

0 comments on commit c1a0271

Please sign in to comment.