Skip to content

Merge pull request #38 from developerfred/dependabot/npm_and_yarn/nex… #16

Merge pull request #38 from developerfred/dependabot/npm_and_yarn/nex…

Merge pull request #38 from developerfred/dependabot/npm_and_yarn/nex… #16

Workflow file for this run

name: Version Bump
on:
push:
branches:
- main
jobs:
version-bump:
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: '20'
- name: Configure Git
run: |
git config --local user.email "github-actions[bot]@users.noreply.github.com"
git config --local user.name "github-actions[bot]"
- name: Bump version and push tag
id: bump_version
uses: mathieudutour/github-tag-action@v6.1
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
default_bump: patch
release_branches: main
dry_run: false
- name: Update package.json with new version
run: |
npm version ${{ steps.bump_version.outputs.new_tag }} --no-git-tag-version
- name: Commit version bump
run: |
git add package.json
git commit -m "chore: bump version to ${{ steps.bump_version.outputs.new_tag }}"
git push
- name: Create GitHub Release
uses: ncipollo/release-action@v1
with:
tag: ${{ steps.bump_version.outputs.new_tag }}
name: Release ${{ steps.bump_version.outputs.new_tag }}
body: ${{ steps.bump_version.outputs.changelog }}
generateReleaseNotes: true