workflow fix attempt#3 #4
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Rust | |
on: | |
push: | |
branches: ["master"] | |
pull_request: | |
branches: ["master"] | |
env: | |
CARGO_TERM_COLOR: always | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Install libtorch | |
run: | | |
# Add your libtorch installation commands here | |
# For example, you might download and extract the libtorch archive | |
wget https://download.pytorch.org/libtorch/cpu/libtorch-cxx11-abi-shared-with-deps-2.0.0%2Bcpu.zip | |
unzip libtorch-cxx11-abi-shared-with-deps-2.0.0+cpu.zip && rm libtorch-cxx11-abi-shared-with-deps-2.0.0+cpu.zip | |
export LIBTORCH=$(pwd)/libtorch | |
export LD_LIBRARY_PATH=$(pwd)/libtorch/lib:$LD_LIBRARY_PATH | |
echo $LIBTORCH | |
echo $LD_LIBRARY_PATH | |
ls . | |
- name: Build and test Rust project | |
run: | | |
cargo build --release | |
cargo test |