Skip to content

Commit

Permalink
ci: Add Rust and Foundry configuration to CircleCI workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
raffaele-oplabs committed Jan 31, 2025
1 parent 0c82baf commit 7ef36e8
Showing 1 changed file with 55 additions and 6 deletions.
61 changes: 55 additions & 6 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,57 @@ executors:
default:
docker:
- image: us-docker.pkg.dev/oplabs-tools-artifacts/images/ci-builder:v0.47.3
rust:
docker:
- image: cimg/rust:1.75.0 # CircleCI's Rust Docker image
working_directory: ~/project


commands:
install_rust_toolchain:
steps:
- run:
name: Install Rust nightly
command: |
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y --default-toolchain nightly
source "$HOME/.cargo/env"
install_foundry:
steps:
- run:
name: Install Foundry
command: |
curl -L https://foundry.paradigm.xyz | bash
export PATH="$PATH:/root/.foundry/bin"
foundryup --version nightly
install_just:
steps:
- run:
name: Install just
command: |
curl --proto '=https' --tlsv1.2 -sSf https://just.systems/install.sh | bash -s -- --to /usr/local/bin
jobs:
rust-init:
executor: rust
environment:
CARGO_TERM_COLOR: always
steps:
- checkout
- install_rust_toolchain
- install_foundry
- install_just
- run:
name: Generate testdata
command: just testdata
# Persist workspace for other jobs
- persist_to_workspace:
root: .
paths:
- .

foundry-check:
executor: default
environment:
Expand All @@ -33,11 +82,11 @@ jobs:
workflows:
version: 2
foundry-workflow:
sol-test-workflow:
jobs:
- foundry-check
# - foundry-check:
# filters:
# branches:
# only:
# - main

rust-test-workflow:
jobs:
- rust-init

0 comments on commit 7ef36e8

Please sign in to comment.