forked from xuhaoyang/ClashForAndroid
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Showing
6 changed files
with
152 additions
and
50 deletions.
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,83 @@ | ||
name: build_release | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
tags: | ||
- '*' # | ||
workflow_dispatch: | ||
|
||
jobs: | ||
BuildRelease: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout Repository | ||
uses: actions/checkout@v3 | ||
|
||
- name: Checkout submodules | ||
run: git submodule update --init --recursive --remote | ||
|
||
- name: Setup Java | ||
uses: actions/setup-java@v3 | ||
with: | ||
distribution: 'zulu' | ||
java-version: 17 | ||
|
||
- name: Setup Go | ||
uses: actions/setup-go@v3 | ||
with: | ||
go-version: "1.20" | ||
|
||
- uses: actions/cache@v3 | ||
with: | ||
path: | | ||
~/.cache/go-build | ||
~/go/pkg/mod | ||
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }} | ||
restore-keys: | | ||
${{ runner.os }}-go- | ||
- name: Signing properties | ||
env: | ||
SIGNING_STORE_PASSWORD: ${{ secrets.SIGNING_STORE_PASSWORD }} | ||
SIGNING_KEY_ALIAS: ${{ secrets.SIGNING_KEY_ALIAS }} | ||
SIGNING_KEY_PASSWORD: ${{ secrets.SIGNING_KEY_PASSWORD }} | ||
run: | | ||
touch signing.properties | ||
echo keystore.password="$SIGNING_STORE_PASSWORD" > signing.properties | ||
echo key.alias="$SIGNING_KEY_ALIAS" >> signing.properties | ||
echo key.password="$SIGNING_KEY_PASSWORD" >> signing.properties | ||
echo "cat signing.properties" | ||
cat signing.properties | ||
- name: Release Build | ||
if: success() | ||
uses: gradle/gradle-build-action@v2 | ||
with: | ||
arguments: --no-daemon app:assembleMetaRelease | ||
|
||
- name: Set current tag | ||
id: current_tag | ||
run: echo ::set-output name=tag::$(git describe --tags --abbrev=0) | ||
|
||
- name: Tag Repo | ||
uses: richardsimko/update-tag@v1 | ||
with: | ||
tag: ${{ steps.current_tag.outputs.tag }} | ||
tag_name: ${{ steps.current_tag.outputs.tag }} | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
|
||
- name: Upload Release | ||
uses: softprops/action-gh-release@v1 | ||
if: ${{ success() }} | ||
with: | ||
tag: ${{ github.ref_name }} | ||
tag_name: ${{ github.ref_name }} | ||
files: app/build/outputs/apk/meta/release/* | ||
generate_release_notes: true | ||
|
||
- name: Release Changelog Builder | ||
uses: mikepenz/[email protected] |
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
Submodule clash
updated
from da67ca to 1a49a3
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