mirror of
https://github.com/2dust/v2rayN.git
synced 2026-04-16 04:25:45 +00:00
63 lines
1.7 KiB
YAML
63 lines
1.7 KiB
YAML
name: release Windows desktop (Avalonia UI)
|
|
|
|
on:
|
|
workflow_dispatch:
|
|
inputs:
|
|
release_tag:
|
|
required: false
|
|
type: string
|
|
push:
|
|
branches:
|
|
- master
|
|
|
|
env:
|
|
OutputArch: "windows-64"
|
|
OutputArchArm: "windows-arm64"
|
|
OutputPath64: "${{ github.workspace }}/v2rayN/Release/windows-desktop-64"
|
|
OutputPathArm64: "${{ github.workspace }}/v2rayN/Release/windows-desktop-arm64"
|
|
|
|
jobs:
|
|
build:
|
|
strategy:
|
|
matrix:
|
|
arch: [ x64, arm64 ]
|
|
uses: ./.github/workflows/build.yml
|
|
with:
|
|
target: windows-desktop
|
|
arch: ${{ matrix.arch }}
|
|
|
|
release-zip:
|
|
runs-on: ubuntu-latest
|
|
needs: build
|
|
if: inputs.release_tag != ''
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v6.0.2
|
|
|
|
- name: Restore build artifacts x64
|
|
uses: actions/download-artifact@v8
|
|
with:
|
|
name: v2rayN-windows-dekstop-x64
|
|
path: ${{ github.workspace }}/v2rayN/Release
|
|
|
|
- name: Restore build artifacts arm64
|
|
uses: actions/download-artifact@v8
|
|
with:
|
|
name: v2rayN-windows-dekstop-arm64
|
|
path: ${{ github.workspace }}/v2rayN/Release
|
|
|
|
- name: Package release zip archive
|
|
run: |
|
|
chmod 755 package-release-zip.sh
|
|
./package-release-zip.sh $OutputArch $OutputPath64
|
|
mv "v2rayN-${OutputArch}.zip" "v2rayN-${OutputArch}-desktop.zip"
|
|
./package-release-zip.sh $OutputArchArm $OutputPathArm64
|
|
mv "v2rayN-${OutputArchArm}.zip" "v2rayN-${OutputArchArm}-desktop.zip"
|
|
|
|
- name: Upload zip archive to release
|
|
uses: svenstaro/upload-release-action@v2
|
|
with:
|
|
file: ${{ github.workspace }}/v2rayN*.zip
|
|
tag: ${{ github.event.inputs.release_tag }}
|
|
file_glob: true
|
|
prerelease: true
|