Skip to content

Commit

Permalink
ci: fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Pylogmon committed Mar 14, 2023
1 parent af1d679 commit 2983c06
Showing 1 changed file with 25 additions and 26 deletions.
51 changes: 25 additions & 26 deletions .github/workflows/package.yml
Original file line number Diff line number Diff line change
Expand Up @@ -69,10 +69,6 @@ jobs:
matrix:
platform: [macos-latest]
target: [aarch64-apple-darwin, x86_64-apple-darwin]
bundle: [dmg, macos]
include:
- bundle: dmg
ext: dmg

runs-on: ${{ matrix.platform }}
steps:
Expand All @@ -96,13 +92,13 @@ jobs:
run: pnpm install
- name: Build and Package
run: |
pnpm tauri build --target ${{ matrix.target }} -b ${{ matrix.bundle }}
pnpm tauri build --target ${{ matrix.target }}
- name: Upload Artifacts
uses: actions/upload-artifact@v3
with:
name: pot_${{ matrix.target }}.${{ matrix.ext }}
path: src-tauri/target/${{ matrix.target }}/release/bundle/${{ matrix.bundle }}/*.${{ matrix.ext }}
name: pot_${{ matrix.target }}.dmg
path: src-tauri/target/${{ matrix.target }}/release/bundle/dmg/*.dmg
if-no-files-found: error

- name: Upload Release
Expand All @@ -111,20 +107,14 @@ jobs:
with:
body_path: CHANGELOG
token: ${{ secrets.RELEASE_TOKEN }}
files: src-tauri/target/${{ matrix.target }}/release/bundle/${{ matrix.bundle }}/*.${{ matrix.ext }}
files: src-tauri/target/${{ matrix.target }}/release/bundle/dmg/*.dmg
build-for-linux:
needs: change-version
strategy:
fail-fast: false
matrix:
platform: [ubuntu-latest]
target: [x86_64-unknown-linux-gnu]
bundle: [deb, appimage]
include:
- bundle: deb
ext: deb
- bundle: appimage
ext: AppImage

runs-on: ${{ matrix.platform }}
steps:
Expand Down Expand Up @@ -152,31 +142,40 @@ jobs:
run: pnpm install
- name: Build and Package
run: |
pnpm tauri build --target ${{ matrix.target }} -b ${{ matrix.bundle }}
pnpm tauri build --target ${{ matrix.target }}
- name: Upload Artifacts
uses: actions/upload-artifact@v3
with:
name: pot_${{ matrix.target }}.${{ matrix.ext }}
path: src-tauri/target/${{ matrix.target }}/release/bundle/${{ matrix.bundle }}/*.${{ matrix.ext }}
name: pot_${{ matrix.target }}.deb
path: src-tauri/target/${{ matrix.target }}/release/bundle/deb/*.deb
if-no-files-found: error
- name: Upload Artifacts
uses: actions/upload-artifact@v3
with:
name: pot_${{ matrix.target }}.AppImage
path: src-tauri/target/${{ matrix.target }}/release/bundle/appimage/*.AppImage
if-no-files-found: error
- name: Upload Release
if: startsWith(github.ref, 'refs/tags')
uses: softprops/action-gh-release@v1
with:
body_path: CHANGELOG
token: ${{ secrets.RELEASE_TOKEN }}
files: src-tauri/target/${{ matrix.target }}/release/bundle/deb/*.deb
- name: Upload Release
if: startsWith(github.ref, 'refs/tags')
uses: softprops/action-gh-release@v1
with:
body_path: CHANGELOG
token: ${{ secrets.RELEASE_TOKEN }}
files: src-tauri/target/${{ matrix.target }}/release/bundle/${{ matrix.bundle }}/*.${{ matrix.ext }}
files: src-tauri/target/${{ matrix.target }}/release/bundle/appimage/*.AppImage
build-for-windows:
needs: change-version-for-windows
strategy:
fail-fast: false
matrix:
platform: [windows-latest]
target: [x86_64-pc-windows-msvc]
bundle: [msi]
include:
- bundle: msi
ext: msi

runs-on: ${{ matrix.platform }}
steps:
Expand All @@ -200,17 +199,17 @@ jobs:
run: pnpm install
- name: Build and Package
run: |
pnpm tauri build --target ${{ matrix.target }} -b ${{ matrix.bundle }}
pnpm tauri build --target ${{ matrix.target }}
- name: Upload Artifacts
uses: actions/upload-artifact@v3
with:
name: pot_${{ matrix.target }}.${{ matrix.ext }}
path: src-tauri/target/${{ matrix.target }}/release/bundle/${{ matrix.bundle }}/*.${{ matrix.ext }}
name: pot_${{ matrix.target }}.msi
path: src-tauri/target/${{ matrix.target }}/release/bundle/msi/*.msi
if-no-files-found: error
- name: Upload Release
if: startsWith(github.ref, 'refs/tags')
uses: softprops/action-gh-release@v1
with:
body_path: CHANGELOG
token: ${{ secrets.RELEASE_TOKEN }}
files: src-tauri/target/${{ matrix.target }}/release/bundle/${{ matrix.bundle }}/*.${{ matrix.ext }}
files: src-tauri/target/${{ matrix.target }}/release/bundle/msi/*.msi

0 comments on commit 2983c06

Please sign in to comment.