-
-
Notifications
You must be signed in to change notification settings - Fork 107
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
1c75099
commit 0d7e45b
Showing
1 changed file
with
42 additions
and
0 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
name: NPM Version Patch and PR | ||
|
||
on: | ||
push: | ||
branches: | ||
- main # Trigger the action when a push is made to the main branch | ||
|
||
jobs: | ||
version-patch: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v3 | ||
|
||
- name: Set up Node.js | ||
uses: actions/setup-node@v3 | ||
with: | ||
node-version: '20' | ||
|
||
- name: Bump version | ||
working-directory: apps/web | ||
run: npm version patch | ||
|
||
- name: Commit changes | ||
working-directory: apps/web | ||
run: | | ||
git add package.json | ||
git commit -m "Bump version in apps/web" | ||
- name: Push changes | ||
run: | | ||
git push origin main | ||
- name: Create Pull Request | ||
uses: peter-evans/create-pull-request@v4 | ||
with: | ||
token: ${{ secrets.GITHUB_TOKEN }} | ||
commit-message: "Bump version in apps/web" | ||
branch: "main" | ||
title: "Bump version in apps/web" | ||
body: "Bump version in apps/web folder using npm version patch" | ||
base: "main" |