Skip to content

Commit

Permalink
version patching correctly again in github workflows
Browse files Browse the repository at this point in the history
  • Loading branch information
mohit-bhandari45 committed Feb 3, 2025
1 parent d8e9d8c commit 29420b5
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion .github/workflows/publish.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@ jobs:
steps:
- name: Checkout Code
uses: actions/checkout@v3
with:
persist-credentials: false # Disable default GITHUB_TOKEN

- name: Set up Node.js
uses: actions/setup-node@v3
Expand All @@ -34,11 +36,16 @@ jobs:
run: |
git add .
git diff --cached --quiet || git commit -m "chore: commit pending changes"
git push origin master
- name: Bump version and commit
run: |
npm version patch -m "Upgrade to %s"
git add package.json package-lock.json
git commit -m "chore: bump version"
- name: Push changes
run: |
git remote set-url origin https://x-access-token:${{ secrets.PAT_TOKEN }}@github.com/mohit-bhandari45/Module.git
git push origin master --follow-tags
- name: Publish to npm
Expand Down

0 comments on commit 29420b5

Please sign in to comment.