From 8a461fdb250db7ba86ee5283c29842dcc99efe5e Mon Sep 17 00:00:00 2001 From: KT Date: Sat, 10 Jun 2023 22:55:26 +0800 Subject: [PATCH] chore: Add release action --- .github/workflows/Release.yml | 34 ++++++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) create mode 100644 .github/workflows/Release.yml diff --git a/.github/workflows/Release.yml b/.github/workflows/Release.yml new file mode 100644 index 00000000..16693874 --- /dev/null +++ b/.github/workflows/Release.yml @@ -0,0 +1,34 @@ +name: Release + +on: + push: + tags: + - "*" + +permissions: + contents: write + packages: write + +jobs: + release_archive: + runs-on: ubuntu-latest + if: github.repository == 'KT-Yeh/mihomo' + + steps: + - name: Checkout + uses: actions/checkout@v3 + with: + submodules: true + + - name: Archive Release + uses: thedoctor0/zip-release@0.7.1 + with: + type: zip + filename: 'mihomo_${{ github.ref_name }}.zip' + exclusions: '*.git*' + + - name: Release + uses: softprops/action-gh-release@v1 + with: + generate_release_notes: true + files: 'mihomo_${{ github.ref_name }}.zip' \ No newline at end of file