Skip to content

Upgrade the dependencies, fix the routing, and remove unused dependen… #16

Upgrade the dependencies, fix the routing, and remove unused dependen…

Upgrade the dependencies, fix the routing, and remove unused dependen… #16

Workflow file for this run

name: VISP Build
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
workflow_dispatch:
env:
CARGO_TERM_COLOR: always
jobs:
build:
runs-on: windows-latest
permissions:
contents: write
steps:
- name: Checkout sources
uses: actions/checkout@v4
- name: Get rust toolchain
uses: dtolnay/rust-toolchain@master
with:
toolchain: 1.76.0
targets: x86_64-pc-windows-msvc,wasm32-unknown-unknown
- uses: cargo-bins/cargo-binstall@main
- uses: Swatinem/rust-cache@v2
# Look for a fix with bundling.
- name: Install Dioxus CLI
run: cargo binstall --no-confirm dioxus-cli@0.5.0-alpha.2 --force
- name: Build Web
run: dx build --platform web --release
- name: Archive Web Production Artifacts
uses: actions/upload-artifact@v4
with:
name: web-dist
path: |
dist/assets/
dist/index.html
- name: Deploy to Vercel
if: "github.event_name == 'push' && endsWith(github.ref, 'refs/heads/main')" # Deploy to prod if it is a push to `main`
uses: amondnet/vercel-action@v20
with:
vercel-token: ${{ secrets.VERCEL_TOKEN }} # Required
vercel-args: '--prod'
vercel-org-id: ${{ secrets.VERCEL_ORG_ID }} # Required
vercel-project-id: ${{ secrets.VERCEL_PROJ_ID }} # Required
working-directory: ./dist
- name: Build and Bundle Desktop
run: dx bundle --platform desktop --release
- name: Archive Desktop Production Artifacts
uses: actions/upload-artifact@v4
with:
name: desktop-dist
path: |
dist/bundle/
dist/visp.exe