-
-
Notifications
You must be signed in to change notification settings - Fork 223
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
build: add workflow to prepare a release
- Loading branch information
1 parent
4f51c2e
commit 0b7105f
Showing
2 changed files
with
40 additions
and
1 deletion.
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
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,39 @@ | ||
# /.github/workflows/release.yaml | ||
# GitHub actions workflow to prepare a release. | ||
|
||
name: Release | ||
|
||
on: | ||
workflow_dispatch: | ||
inputs: | ||
version: | ||
description: | | ||
The new version to bump the package to; any value accepted by the | ||
`npm version` command. | ||
default: 'patch' | ||
|
||
jobs: | ||
prepare-release: | ||
name: Prepare Release | ||
runs-on: ubuntu-latest | ||
permissions: | ||
contents: write | ||
id-token: write | ||
steps: | ||
- name: Checkout the repository | ||
uses: actions/checkout@v4 | ||
- uses: actions/checkout@v4 | ||
- name: Configure Git Credentials | ||
run: | | ||
git config user.name github-actions[bot] | ||
git config user.email 41898282+github-actions[bot]@users.noreply.github.com | ||
- uses: actions/setup-node@v4 | ||
with: | ||
node-version: lts/* | ||
registry-url: https://registry.npmjs.org/ | ||
- name: Bump version | ||
run: npm version "${{ github.event.inputs.version }}" | ||
- name: Upload git tags | ||
run: | | ||
git push | ||
git push --tags |