Skip to content

Adds a Justfile and a composite action. #210

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jul 14, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
56 changes: 56 additions & 0 deletions .github/actions/setup/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
# Common steps we do in most of our jobs

name: Setup a Job

inputs:
criticalup:
description: 'Install Criticalup'
required: false
default: ""
channel:
description: 'Rust channel'
required: false
default: "stable"
cache:
description: "Workspace to cache with Swatinem/rust-cache@v2"
required: false
default: ""
target:
description: "Extra target for rustup to install"
required: false
default: ""

runs:
using: "composite"
steps:
- name: Install CriticalUp (optional)
if: ${{ inputs.criticalup != '' }}
shell: bash
env:
CRITICALUP_VERSION: ${{ inputs.criticalup }}
run: |
curl --proto '=https' --tlsv1.2 -LsSf https://github.com/ferrocene/criticalup/releases/download/${CRITICALUP_VERSION}/criticalup-installer.sh | sh
- name: Install Just 1.42
uses: extractions/setup-just@v3
with:
just-version: 1.42
- name: Update Rust
shell: bash
run: |
rustup set profile minimal
rustup update ${RUSTUP_CHANNEL} --no-self-update
rustup default ${RUSTUP_CHANNEL}
env:
RUSTUP_CHANNEL: ${{ inputs.channel }}
- name: Install Target
if: ${{ inputs.target != '' }}
shell: bash
env:
RUSTUP_TARGET: ${{ inputs.target }}
run: |
rustup target add ${RUSTUP_TARGET}
- name: Setup Rust Cache
if: ${{ inputs.cache != '' }}
uses: Swatinem/rust-cache@v2
with:
workspaces: ${{ inputs.cache }}
Loading