File tree Expand file tree Collapse file tree 2 files changed +15
-6
lines changed
Expand file tree Collapse file tree 2 files changed +15
-6
lines changed Original file line number Diff line number Diff line change 3434 asset_name : windows
3535 arch : x86_64
3636 env :
37- BINARY_NAME : zparse -${{ matrix.platform.asset_name }}-${{ matrix.platform.arch }}${{ matrix.platform.os == 'windows-latest' && '.exe' || '' }}
37+ BINARY_NAME : keywatch -${{ matrix.platform.asset_name }}-${{ matrix.platform.arch }}${{ matrix.platform.os == 'windows-latest' && '.exe' || '' }}
3838
3939 steps :
4040 - name : Checkout repository
@@ -69,15 +69,15 @@ jobs:
6969 # Build the specific package
7070 - name : Build Binary
7171 run : |
72- cargo build --release --target ${{ matrix.platform.target }} -p zparse
72+ cargo build --release --target ${{ matrix.platform.target }}
7373 env :
7474 CARGO_TARGET_AARCH64_APPLE_DARWIN_LINKER : aarch64-apple-darwin-gcc
7575
7676 - name : Prepare Asset
7777 shell : bash
7878 run : |
7979 mkdir -p release
80- cp target/${{ matrix.platform.target }}/release/zparse ${{ matrix.platform.os == 'windows-latest' && '.exe' || '' }} \
80+ cp target/${{ matrix.platform.target }}/release/key-watch ${{ matrix.platform.os == 'windows-latest' && '.exe' || '' }} \
8181 release/${{ env.BINARY_NAME }}
8282
8383 # Create checksum
9494 - name : Create Release
9595 uses : softprops/action-gh-release@v1
9696 with :
97- name : " zParse ${{ github.ref_name }}"
97+ name : " KeyWatch ${{ github.ref_name }}"
9898 files : |
9999 release/${{ env.BINARY_NAME }}
100100 release/${{ env.BINARY_NAME }}.sha256
Original file line number Diff line number Diff line change @@ -43,6 +43,11 @@ read -p "Do you want to commit these changes and create tag v$VERSION? (y/n) " -
4343echo
4444if [[ $REPLY =~ ^[Yy]$ ]]
4545then
46+ # Stash current changes and checkout to release branch
47+ git stash
48+ git checkout -b release-$VERSION
49+ git stash pop
50+
4651 # Commit changes
4752 git add Cargo.toml CHANGELOG.md
4853 git commit -m " chore: release version $VERSION "
5156 git tag -a " v$VERSION " -m " KeyWatch v$VERSION "
5257
5358 echo " Pushing changes..."
54- git push origin main " v$VERSION "
55-
59+ git push origin release-$VERSION " v$VERSION "
60+
61+ # Checkout to main branch and delete release branch
62+ git checkout main
63+ git branch -D release-$VERSION
64+
5665 echo " KeyWatch release v$VERSION prepared and pushed!"
5766else
5867 # Revert changes if user doesn't confirm
You can’t perform that action at this time.
0 commit comments