create release

Signed-off-by: bggRGjQaUbCoE <githubaccount56556@proton.me>
This commit is contained in:
bggRGjQaUbCoE
2025-10-19 12:10:56 +08:00
parent 6e1ceb1277
commit 0ae4157384
6 changed files with 124 additions and 7 deletions

View File

@@ -47,11 +47,18 @@ on:
default: true default: true
type: boolean type: boolean
tag:
description: "tag"
required: false
default: ""
type: string
jobs: jobs:
android: android:
if: ${{ github.event_name == 'pull_request' || github.event.inputs.build_android == 'true' }} if: ${{ github.event_name == 'pull_request' || github.event.inputs.build_android == 'true' }}
name: Release Android name: Release Android
runs-on: ubuntu-latest runs-on: ubuntu-latest
permissions: write-all
steps: steps:
- name: 代码迁出 - name: 代码迁出
@@ -108,43 +115,67 @@ jobs:
done done
shell: bash shell: bash
- name: Release
if: ${{ github.event.inputs.tag != '' }}
uses: softprops/action-gh-release@v2
with:
tag_name: ${{ github.event.inputs.tag }}
name: ${{ github.event.inputs.tag }}
files: |
PiliPlus_android_*.apk
- name: 上传 - name: 上传
uses: actions/upload-artifact@v4 uses: actions/upload-artifact@v4
with: with:
name: app-arm64-v8a name: Android_arm64-v8a
path: | path: |
PiliPlus_android_*_arm64-v8a.apk PiliPlus_android_*_arm64-v8a.apk
- name: 上传 - name: 上传
uses: actions/upload-artifact@v4 uses: actions/upload-artifact@v4
with: with:
name: app-armeabi-v7a name: Android_armeabi-v7a
path: | path: |
PiliPlus_android_*_armeabi-v7a.apk PiliPlus_android_*_armeabi-v7a.apk
- name: 上传 - name: 上传
uses: actions/upload-artifact@v4 uses: actions/upload-artifact@v4
with: with:
name: app-x86_64 name: Android_x86_64
path: | path: |
PiliPlus_android_*_x86_64.apk PiliPlus_android_*_x86_64.apk
ios: ios:
if: ${{ github.event_name == 'pull_request' || github.event.inputs.build_ios == 'true' }} if: ${{ github.event_name == 'pull_request' || github.event.inputs.build_ios == 'true' }}
uses: ./.github/workflows/ios.yml uses: ./.github/workflows/ios.yml
permissions: write-all
with:
tag: github.event.inputs.tag
mac: mac:
if: ${{ github.event_name == 'pull_request' || github.event.inputs.build_mac == 'true' }} if: ${{ github.event_name == 'pull_request' || github.event.inputs.build_mac == 'true' }}
uses: ./.github/workflows/mac.yml uses: ./.github/workflows/mac.yml
permissions: write-all
with:
tag: github.event.inputs.tag
win_x64: win_x64:
if: ${{ github.event_name == 'pull_request' || github.event.inputs.build_win_x64 == 'true' }} if: ${{ github.event_name == 'pull_request' || github.event.inputs.build_win_x64 == 'true' }}
uses: ./.github/workflows/win_x64.yml uses: ./.github/workflows/win_x64.yml
permissions: write-all
with:
tag: github.event.inputs.tag
linux_x64: linux_x64:
if: ${{ github.event_name == 'pull_request' || github.event.inputs.build_linux_x64 == 'true' }} if: ${{ github.event_name == 'pull_request' || github.event.inputs.build_linux_x64 == 'true' }}
uses: ./.github/workflows/linux_x64.yml uses: ./.github/workflows/linux_x64.yml
permissions: write-all
with:
tag: github.event.inputs.tag
linux_arm64: linux_arm64:
if: ${{ github.event_name == 'pull_request' || github.event.inputs.build_linux_arm64 == 'true' }} if: ${{ github.event_name == 'pull_request' || github.event.inputs.build_linux_arm64 == 'true' }}
uses: ./.github/workflows/linux_arm64.yml uses: ./.github/workflows/linux_arm64.yml
permissions: write-all
with:
tag: github.event.inputs.tag

View File

@@ -2,6 +2,12 @@ name: Build for iOS
on: on:
workflow_call: workflow_call:
inputs:
tag:
description: "tag"
required: false
default: ""
type: string
workflow_dispatch: workflow_dispatch:
jobs: jobs:
@@ -30,8 +36,17 @@ jobs:
ln -sf ./build/ios/iphoneos Payload ln -sf ./build/ios/iphoneos Payload
zip -r9 PiliPlus_ios_${{env.version}}.ipa Payload/runner.app zip -r9 PiliPlus_ios_${{env.version}}.ipa Payload/runner.app
- name: Release
if: ${{ github.event.inputs.tag != '' }}
uses: softprops/action-gh-release@v2
with:
tag_name: ${{ github.event.inputs.tag }}
name: ${{ github.event.inputs.tag }}
files: |
PiliPlus_ios_*.ipa
- name: Upload ios release - name: Upload ios release
uses: actions/upload-artifact@v4 uses: actions/upload-artifact@v4
with: with:
name: ios-release name: iOS-release
path: PiliPlus_ios_*.ipa path: PiliPlus_ios_*.ipa

View File

@@ -2,6 +2,12 @@ name: Build for Linux Arm64
on: on:
workflow_call: workflow_call:
inputs:
tag:
description: "tag"
required: false
default: ""
type: string
workflow_dispatch: workflow_dispatch:
jobs: jobs:
@@ -174,6 +180,17 @@ jobs:
printf "完成: PiliPlus_linux_%s_arm64.rpm\n" "${{ env.version }}" printf "完成: PiliPlus_linux_%s_arm64.rpm\n" "${{ env.version }}"
shell: bash shell: bash
- name: Release
if: ${{ github.event.inputs.tag != '' }}
uses: softprops/action-gh-release@v2
with:
tag_name: ${{ github.event.inputs.tag }}
name: ${{ github.event.inputs.tag }}
files: |
PiliPlus_linux_*.tar.gz
PiliPlus_linux_*.deb
PiliPlus_linux_*.rpm
- name: Upload linux targz package - name: Upload linux targz package
uses: actions/upload-artifact@v4 uses: actions/upload-artifact@v4
with: with:

View File

@@ -2,6 +2,12 @@ name: Build for Linux x64
on: on:
workflow_call: workflow_call:
inputs:
tag:
description: "tag"
required: false
default: ""
type: string
workflow_dispatch: workflow_dispatch:
jobs: jobs:
@@ -174,6 +180,17 @@ jobs:
printf "完成: PiliPlus_linux_%s_amd64.rpm\n" "${{ env.version }}" printf "完成: PiliPlus_linux_%s_amd64.rpm\n" "${{ env.version }}"
shell: bash shell: bash
- name: Release
if: ${{ github.event.inputs.tag != '' }}
uses: softprops/action-gh-release@v2
with:
tag_name: ${{ github.event.inputs.tag }}
name: ${{ github.event.inputs.tag }}
files: |
PiliPlus_linux_*.tar.gz
PiliPlus_linux_*.deb
PiliPlus_linux_*.rpm
- name: Upload linux targz package - name: Upload linux targz package
uses: actions/upload-artifact@v4 uses: actions/upload-artifact@v4
with: with:

View File

@@ -2,6 +2,12 @@ name: Build for Mac
on: on:
workflow_call: workflow_call:
inputs:
tag:
description: "tag"
required: false
default: ""
type: string
workflow_dispatch: workflow_dispatch:
jobs: jobs:
@@ -36,8 +42,17 @@ jobs:
- name: Rename DMG - name: Rename DMG
run: mv PiliPlus*.dmg PiliPlus_macos_${{ env.version }}.dmg run: mv PiliPlus*.dmg PiliPlus_macos_${{ env.version }}.dmg
- name: Release
if: ${{ github.event.inputs.tag != '' }}
uses: softprops/action-gh-release@v2
with:
tag_name: ${{ github.event.inputs.tag }}
name: ${{ github.event.inputs.tag }}
files: |
PiliPlus_macos_*.dmg
- name: Upload macos release - name: Upload macos release
uses: actions/upload-artifact@v4 uses: actions/upload-artifact@v4
with: with:
name: macos-release name: macOS-release
path: PiliPlus_macos_*.dmg path: PiliPlus_macos_*.dmg

View File

@@ -2,6 +2,12 @@ name: Build for Windows x64
on: on:
workflow_call: workflow_call:
inputs:
tag:
description: "tag"
required: false
default: ""
type: string
workflow_dispatch: workflow_dispatch:
jobs: jobs:
@@ -45,14 +51,30 @@ jobs:
mv build/windows/x64/runner/Release/* Release/PiliPlus-Win/ mv build/windows/x64/runner/Release/* Release/PiliPlus-Win/
mv dist/**/*.exe PiliPlus-Win-Setup/PiliPlus_windows_${{env.version}}_x64_setup.exe mv dist/**/*.exe PiliPlus-Win-Setup/PiliPlus_windows_${{env.version}}_x64_setup.exe
- name: Compress
if: ${{ github.event.inputs.tag != '' }}
run: |
Compress-Archive -Path "Release/PiliPlus-Win" -DestinationPath "PiliPlus_windows_${{env.version}}_x64.zip"
shell: pwsh
- name: Release
if: ${{ github.event.inputs.tag != '' }}
uses: softprops/action-gh-release@v2
with:
tag_name: ${{ github.event.inputs.tag }}
name: ${{ github.event.inputs.tag }}
files: |
PiliPlus_windows_*.zip
PiliPlus-Win-Setup/PiliPlus_windows_*.exe
- name: Upload windows file release - name: Upload windows file release
uses: actions/upload-artifact@v4 uses: actions/upload-artifact@v4
with: with:
name: PiliPlus_windows_${{env.version}}_x64 name: Windows-file-x64-release
path: Release path: Release
- name: Upload windows setup release - name: Upload windows setup release
uses: actions/upload-artifact@v4 uses: actions/upload-artifact@v4
with: with:
name: windows-setup-x64-release name: Windows-setup-x64-release
path: PiliPlus-Win-Setup path: PiliPlus-Win-Setup