mirror of
https://github.com/babalae/better-genshin-impact.git
synced 2026-05-27 10:15:50 +08:00
63 lines
1.8 KiB
YAML
63 lines
1.8 KiB
YAML
name: mirrorchyan_uploading
|
|
|
|
on:
|
|
workflow_dispatch:
|
|
release:
|
|
types: [released]
|
|
|
|
jobs:
|
|
mirrorchyan_7z:
|
|
runs-on: macos-latest
|
|
steps:
|
|
- name: 📥 Download release
|
|
uses: robinraju/release-downloader@v1.8
|
|
with:
|
|
latest: true
|
|
fileName: "*"
|
|
|
|
- name: Extract 7z
|
|
shell: bash
|
|
run: |
|
|
7z x BetterGI_v*.7z -oun7z
|
|
mv ./BetterGI.Metadata.json ./un7z/BetterGI/.metadata.json
|
|
|
|
- name: Determine version number
|
|
id: get-version
|
|
run: |
|
|
if [ "${{ github.event_name }}" = "release" ]; then
|
|
echo "version=${{ github.event.release.tag_name }}" >> $GITHUB_OUTPUT
|
|
else
|
|
LATEST_TAG=$(curl -s -H "Authorization: Bearer ${{ secrets.GITHUB_TOKEN }}" \
|
|
https://api.github.com/repos/${{ github.repository }}/releases/latest \
|
|
| jq -r '.tag_name')
|
|
echo "version=$LATEST_TAG" >> $GITHUB_OUTPUT
|
|
fi
|
|
|
|
- name: Upload Zip
|
|
uses: MirrorChyan/uploading-action@v1
|
|
with:
|
|
filetype: local
|
|
mirrorchyan_rid: BGI
|
|
working-directory: ./un7z/
|
|
pick_files: '["BetterGI"]'
|
|
version_name: ${{ steps.get-version.outputs.version }}
|
|
upload_token: ${{ secrets.MirrorChyanUploadToken }}
|
|
os: win
|
|
arch: x64
|
|
|
|
mirrorchyan_exe:
|
|
runs-on: macos-latest
|
|
steps:
|
|
- uses: MirrorChyan/uploading-action@v1
|
|
with:
|
|
filetype: latest-release
|
|
filename: "BetterGI.Install.*.exe"
|
|
extra_zip: true
|
|
mirrorchyan_rid: BGI
|
|
|
|
github_token: ${{ secrets.GITHUB_TOKEN }}
|
|
owner: babalae
|
|
repo: better-genshin-impact
|
|
upload_token: ${{ secrets.MirrorChyanUploadToken }}
|
|
|