Skip to content

Commit

Permalink
chore: Corrección de errores y mejoras en el lanzamiento
Browse files Browse the repository at this point in the history
  • Loading branch information
BarraR3port committed Jun 11, 2024
1 parent 1a74ac5 commit 95db691
Showing 1 changed file with 6 additions and 49 deletions.
55 changes: 6 additions & 49 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ jobs:
runs-on: ${{ matrix.platform }}
steps:
- name: Checkout repository
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Install Rust
uses: dtolnay/rust-toolchain@stable
Expand All @@ -94,59 +94,16 @@ jobs:
sudo apt-get update
sudo apt install -y --no-install-recommends libwebkit2gtk-4.1-dev libgtk-3-dev libayatana-appindicator3-dev librsvg2-dev patchelf
- name: Install bun in Windows
if: matrix.platform == 'windows-latest'
run: |
iwr https://bun.sh/install.ps1 | iex
echo "C:\Users\runneradmin\.bun\bin" >> $env:GITHUB_PATH
- name: Verify Bun Installation
if: matrix.platform == 'windows-latest'
run: bun --version

- name: Install bun in other platforms
if: matrix.platform != 'windows-latest'
run: npm install -g bun
- name: Install bun
uses: oven-sh/setup-bun@v1

- name: Install frontend dependencies
- name: Install dependencies
run: bun install

- name: Build the app
uses: tauri-apps/tauri-action@v0
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NEXT_PUBLIC_APP_URL: ${{ secrets.NEXT_PUBLIC_APP_URL }}
with:
releaseId: ${{ needs.create-or-find-release.outputs.release_id }}

- name: Upload artifacts to release
if: matrix.platform == 'ubuntu-latest'
run: |
assets=($(find ./src-tauri/target/release/bundle -type f))
for asset in "${assets[@]}"; do
echo "Uploading $asset"
gh release upload ${{ needs.create-or-find-release.outputs.release_id }} "$asset" --clobber
done
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

publish-release:
permissions:
contents: write
runs-on: ubuntu-20.04
needs: [create-or-find-release, build-tauri]

steps:
- name: Publish release
id: publish-release
uses: actions/github-script@v6
env:
release_id: ${{ needs.create-or-find-release.outputs.release_id }}
with:
script: |
github.rest.repos.updateRelease({
owner: context.repo.owner,
repo: context.repo.repo,
release_id: process.env.release_id,
draft: false,
prerelease: false
})
releaseId: ${{ needs.create-or-find-release.outputs.release_id }}

0 comments on commit 95db691

Please sign in to comment.