Skip to content
This repository has been archived by the owner on Jan 10, 2025. It is now read-only.

Update rust.yml

Update rust.yml #2

Workflow file for this run

To modify the GitHub Actions workflow to build the Rust project for Windows, you can add a new job that runs on a Windows runner (`windows-latest`). Here is an updated version of your workflow file:
```yaml

Check failure on line 3 in .github/workflows/rust.yml

View workflow run for this annotation

GitHub Actions / .github/workflows/rust.yml

Invalid workflow file

You have an error in your yaml syntax on line 3
name: Rust
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
env:
CARGO_TERM_COLOR: always
jobs:
build-linux:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Build
run: cargo build --verbose
# - name: Run tests
# run: cargo test --verbose
build-windows:
runs-on: windows-latest
steps:
- uses: actions/checkout@v4
- name: Install Rust
run: rustup install stable-x86_64-pc-windows-msvc
- name: Set up Rust toolchain
run: rustup default stable-x86_64-pc-windows-msvc
- name: Build
run: cargo build --verbose
# - name: Run tests
# run: cargo test --verbose