-
Notifications
You must be signed in to change notification settings - Fork 8
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
64dbe2a
commit 6335274
Showing
3 changed files
with
54 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
on: | ||
push: | ||
tags: | ||
- "v*" | ||
|
||
name: Create Release | ||
|
||
jobs: | ||
build: | ||
name: Create Release | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
|
||
- name: Release | ||
uses: softprops/action-gh-release@v1 | ||
with: | ||
body: | | ||
Please refer to [CHANGELOG.md](https://github.com/DongKyuuuu/vue3-recaptcha-v2/blob/main/CHANGELOG.md) for details. |
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,32 @@ | ||
# #!/bin/bash | ||
set -e | ||
|
||
BUMP_LIST=("major" "minor" "patch") | ||
|
||
echo "Current version:" $(grep version package.json | sed -E 's/^.*"([0-9][^"]+)".*$/\1/') | ||
echo | ||
for i in "${!BUMP_LIST[@]}"; do | ||
echo " $(($i + 1)). ${BUMP_LIST[$i]}" | ||
done | ||
read - p "Select version 👉" -n 1 -r | ||
BUMP=${BUMP_LIST[$REPLY - 1]} | ||
|
||
# Bump version | ||
yarn version $BUMP | ||
yarn build | ||
|
||
# ChangeLog | ||
yarn changelog | ||
echo "Please check the git history and the changelog and press enter" | ||
read OKAY | ||
|
||
# Commit and tag | ||
git add CHANGELOG.md package.json .yarn/versions/* | ||
git commit -m "release: v$VERSION" | ||
git tag "v$VERSION" | ||
|
||
|
||
# publish | ||
yarn npm publish | ||
git push origin refs/tags/v$VERSION | ||
git push |