Skip to content

Commit

Permalink
Fix gh actions v2 (#82)
Browse files Browse the repository at this point in the history
* * Main do build the project on every pushes without creating a new release
* Release do build and create a new release on every closed PRs branch in main
* Nightly do build and create a new nightly release on every closed PRs in branch in dev

* Rename main

* adding permissions to override releases assets
  • Loading branch information
Slyker authored Apr 16, 2024
1 parent 21bed51 commit 272ddfe
Show file tree
Hide file tree
Showing 3 changed files with 40 additions and 43 deletions.
4 changes: 3 additions & 1 deletion .github/workflows/pr-nightly-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ env:
CI: false
jobs:
publish-tauri:
permissions:
contents: write
strategy:
fail-fast: false
matrix:
Expand All @@ -22,7 +24,7 @@ jobs:
- name: setup node
uses: actions/setup-node@v3
with:
node-version: 16
node-version: 20
- name: install Rust stable
uses: dtolnay/rust-toolchain@stable
- name: install dependencies (ubuntu only)
Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/pr-release-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ env:
CI: false
jobs:
publish-tauri:
permissions:
contents: write
strategy:
fail-fast: false
matrix:
Expand All @@ -22,7 +24,7 @@ jobs:
- name: setup node
uses: actions/setup-node@v3
with:
node-version: 16
node-version: 20
- name: install Rust stable
uses: dtolnay/rust-toolchain@stable
- name: install dependencies (ubuntu only)
Expand Down
Original file line number Diff line number Diff line change
@@ -1,41 +1,34 @@
name: 'Build release'
on:
pull_request:
push:
branches:
- main
env:
CI: false

jobs:
publish-tauri:
strategy:
fail-fast: false
matrix:
platform: [macos-latest, ubuntu-20.04, windows-latest]

runs-on: ${{ matrix.platform }}
steps:
- uses: actions/checkout@v3
- name: setup node
uses: actions/setup-node@v3
with:
node-version: 16
- name: install Rust stable
uses: dtolnay/rust-toolchain@stable
- name: install dependencies (ubuntu only)
if: matrix.platform == 'ubuntu-20.04'
run: |
sudo apt-get update
sudo apt-get install -y libgtk-3-dev libwebkit2gtk-4.0-dev libappindicator3-dev librsvg2-dev patchelf
- name: install app dependencies and build it
run: yarn && yarn build
- uses: tauri-apps/tauri-action@v0
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tagName: Neuz-v__VERSION__ # the action automatically replaces \_\_VERSION\_\_ with the app version
releaseName: 'Neuz v__VERSION__'
releaseBody: 'See the assets to download this version and install.'
releaseDraft: true
prerelease: false
name: 'Push testing build'
on:
push:
branches:
- "**"
env:
CI: false

jobs:
publish-tauri:
strategy:
fail-fast: false
matrix:
platform: [macos-latest, ubuntu-20.04, windows-latest]

runs-on: ${{ matrix.platform }}
steps:
- uses: actions/checkout@v3
- name: setup node
uses: actions/setup-node@v3
with:
node-version: 20
- name: install Rust stable
uses: dtolnay/rust-toolchain@stable
- name: install dependencies (ubuntu only)
if: matrix.platform == 'ubuntu-20.04'
run: |
sudo apt-get update
sudo apt-get install -y libgtk-3-dev libwebkit2gtk-4.0-dev libappindicator3-dev librsvg2-dev patchelf
- name: install app dependencies and build it
run: yarn && yarn build
- uses: tauri-apps/tauri-action@v0
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 comments on commit 272ddfe

Please sign in to comment.