Rename daft cli and bump up version #12
Workflow file for this run
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: run-rust-tests | |
on: | |
pull_request: | |
jobs: | |
run-rust-tests: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Log workflow inputs | |
run: echo "${{ toJson(github.event.inputs) }}" | |
- name: Checkout repo | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 1 | |
- name: Install rust | |
shell: bash | |
run: | | |
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y | |
CARGO_BIN="$HOME/.cargo/bin" | |
echo 'export PATH="$CARGO_BIN:$PATH"' >> $HOME/.bashrc | |
echo "$CARGO_BIN" >> $GITHUB_PATH | |
- name: Install uv | |
shell: bash | |
run: | | |
curl -LsSf https://astral.sh/uv/install.sh | sh | |
UV_BIN="$HOME/.local/bin" | |
echo 'export PATH="$UV_BIN:$PATH"' >> $HOME/.bashrc | |
echo "$UV_BIN" >> $GITHUB_PATH | |
- name: Install (and pin) python version | |
shell: bash | |
run: | | |
uv python install 3.12 | |
uv python pin 3.12 | |
- name: Setup uv environment | |
run: | | |
uv v | |
source .venv/bin/activate | |
uv pip install ray[default] maturin | |
- name: Restore cache | |
uses: actions/cache@v4 | |
with: | |
path: target/release | |
key: ${{ runner.os }}-cargo-deps-${{ hashFiles('**/Cargo.lock') }} | |
restore-keys: ${{ runner.os }}-cargo-deps- | |
- name: Run tests | |
run: | | |
source .venv/bin/activate | |
cargo test --release |