Skip to content

Commit

Permalink
ci: support automatically creating github release (#41)
Browse files Browse the repository at this point in the history
  • Loading branch information
zhu-xiaowei authored Sep 15, 2023
1 parent 2b29c60 commit 9199c03
Show file tree
Hide file tree
Showing 2 changed files with 30 additions and 2 deletions.
11 changes: 11 additions & 0 deletions .github/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
changelog:
categories:
- title: Feature
labels:
- enhancement
- title: Fix
labels:
- bug
- title: Other Changes
labels:
- "*"
21 changes: 19 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,14 @@ env:
jobs:
release:
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- uses: actions/checkout@v3
with:
ref: main
fetch-depth: 0
token : ${{ secrets.PROJECT_TOKEN }}
token: ${{ secrets.PROJECT_TOKEN }}
- name: Modify for next release
run: |
chmod +x release.sh
Expand All @@ -26,4 +28,19 @@ jobs:
git config user.email '${{ vars.USER_EMAIL }}'
git add .
git commit -m 'release: clickstream Android ${{ env.NEW_VERSION }}'
git push
git push
git tag v${{ env.NEW_VERSION }}
git push origin v${{ env.NEW_VERSION }}
- name: Assemble release
run: |
chmod +x gradlew
./gradlew assembleRelease
- name: Create GitHub release
uses: softprops/action-gh-release@v1
with:
name: "Clickstream Android ${{ env.NEW_VERSION }}"
files: |
clickstream/build/outputs/aar/clickstream-release.aar
tag_name: "v${{ env.NEW_VERSION }}"
prerelease: true
generate_release_notes: true

0 comments on commit 9199c03

Please sign in to comment.