diff --git a/.forgejo/workflows/demo.yaml b/.forgejo/workflows/demo.yaml index b1c4612..8790edc 100644 --- a/.forgejo/workflows/demo.yaml +++ b/.forgejo/workflows/demo.yaml @@ -11,9 +11,31 @@ jobs: steps: - name: Checkout code uses: actions/checkout@v4 - + + - name: Install Rust + run: | + curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y --profile minimal + echo "$HOME/.cargo/bin" >> $GITHUB_PATH + rustup default stable + + - name: Verify Rust installation + run: | + rustc --version + cargo --version + + - name: Cache dependencies + uses: actions/cache@v4 + with: + path: | + ~/.cargo/registry + ~/.cargo/git + target + key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }} + restore-keys: | + ${{ runner.os }}-cargo- + - name: Build run: cargo build --verbose - + - name: Test run: cargo test --verbose