Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
61 commits
Select commit Hold shift + click to select a range
a30e22f
fix proxy RA
Dajamante Jan 21, 2026
a18d403
latest beta
Dajamante Jan 21, 2026
461841f
RA
Dajamante Jan 21, 2026
4d06769
clippy warning
Dajamante Jan 21, 2026
b0ea142
enter dir?
Dajamante Jan 21, 2026
7904aec
wip
Dajamante Jan 22, 2026
a8557e5
wip: heredocs do not coexist with bash
Dajamante Jan 22, 2026
8699a86
wip: typo
Dajamante Jan 22, 2026
c4f0d3e
wip: multiline
Dajamante Jan 22, 2026
e1a124e
simplify
Dajamante Jan 22, 2026
825e5f4
probably do not need all packages
Dajamante Jan 22, 2026
7f027ee
wip: testing for red test
Dajamante Jan 22, 2026
f615a4f
wip
Dajamante Jan 22, 2026
bc0db2c
red test
Dajamante Jan 23, 2026
75f06d4
adding beta which merged https://github.com/ferrocene/ferrocene/pull/…
Dajamante Jan 27, 2026
5d19e31
adding other base packages
Dajamante Jan 27, 2026
246d8fd
checking availability rust-analyzer
Dajamante Jan 27, 2026
f06fcb6
test with nightly that merged https://github.com/ferrocene/ferrocene/…
Dajamante Jan 29, 2026
5678dd9
well that was awkward
Dajamante Jan 29, 2026
2ac1385
maybe it needs other packages?
Dajamante Jan 29, 2026
c7bf6b2
linking to use RA directly
Dajamante Jan 30, 2026
80eba59
fresh dir
Dajamante Jan 30, 2026
b01f786
test
Dajamante Jan 30, 2026
34f1b1c
maybe the old install is tripping CI
Dajamante Jan 30, 2026
43334e7
test, passing anas workflow to actions
Dajamante Jan 30, 2026
c2778fc
define shell
Dajamante Jan 30, 2026
0be8788
passing matrix as object
Dajamante Jan 30, 2026
175fede
moving more things to actions
Dajamante Jan 30, 2026
410d5c0
restauring the spaghetti
Dajamante Jan 30, 2026
d84d3e2
removing old ferro installation
Dajamante Jan 30, 2026
537e431
apparently it doesn't want an exectutable
Dajamante Jan 30, 2026
cf43500
typo there
Dajamante Feb 3, 2026
a8f2383
tracking down all versions
Dajamante Feb 3, 2026
d69139e
exec
Dajamante Feb 3, 2026
55b2335
so there is no criticalup installed at the root by shared actions
Dajamante Feb 3, 2026
68a7e65
force reinstalling on clean slate
Dajamante Feb 3, 2026
ad8e1c7
add toolchain file
Dajamante Feb 3, 2026
7ed3165
port to actions
Dajamante Feb 3, 2026
0f18971
clean up part 1
Dajamante Feb 3, 2026
ed9977f
moving cargo test to main workflow
Dajamante Feb 3, 2026
f5aa4ca
cargo now wants binary name
Dajamante Feb 3, 2026
071e02c
cleanup
Dajamante Feb 3, 2026
53c7cdb
cargo + ferro also need bin
Dajamante Feb 3, 2026
2aa7820
make criticalup do something
Dajamante Feb 3, 2026
3eac60e
missing shell
Dajamante Feb 3, 2026
24b0794
commented out the criticalup run workflow for now
Dajamante Feb 3, 2026
6385232
removed cup worflow from both action and workflow
Dajamante Feb 3, 2026
1703df0
criticalup returns -1 when no command
Dajamante Feb 3, 2026
98fa4ec
shell
Dajamante Feb 3, 2026
ae283a0
remove cargo init
Dajamante Feb 3, 2026
123adb9
specify binary
Dajamante Feb 3, 2026
4e0c200
reinstall
Dajamante Feb 3, 2026
f030905
test presence criticalup
Dajamante Feb 3, 2026
a85d7a6
working directory
Dajamante Feb 3, 2026
c5ff50d
finding location
Dajamante Feb 4, 2026
0f55a39
{{ github.workspace }}
Dajamante Feb 4, 2026
70c3f50
need clarity for the different runners
Dajamante Feb 4, 2026
59cc4a0
typo
Dajamante Feb 4, 2026
e523c06
maybe just inputs
Dajamante Feb 4, 2026
c01b005
testing for regression
Dajamante Mar 5, 2026
c7069a0
Revert "testing for regression"
Dajamante Mar 5, 2026
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
110 changes: 110 additions & 0 deletions .github/actions/criticalup-config/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,110 @@
# SPDX-FileCopyrightText: The Ferrocene Developers
# SPDX-License-Identifier: MIT OR Apache-2.0

---

name: "Install criticalup"
description: "Configure repo for criticalup use"
inputs:
token:
description: The CriticalUp token to use (use a GHA Secret)
required: true
path:
description: The installation path
required: true
matrix:
description: Platforms to run on
required: true
runner:
description: OS to run
required: true

runs:
using: composite
steps:

- name: Establish paths inside composite action
shell: bash
run: |
echo "pwd $(pwd)"
echo "input path: ${{ inputs.path }}"

- name: Download artifacts
uses: actions/download-artifact@v4
with:
name: criticalup-${{ matrix.target }}.${{ runner.os == 'Windows' && 'zip' || 'tar.xz' }}
path: ${{ inputs.path }}

- name: Unpack archive
shell: bash
if: ${{ runner.os == 'Windows' }}
working-directory: ${{ inputs.path }}
run: |
powershell -c "Expand-Archive criticalup-${{ matrix.target }}.zip"
echo "working-directory: ${{ github.workspace }}/${{ inputs.path }}"
mv criticalup-${{ matrix.target }}/criticalup.exe criticalup.exe

- name: Unpack archive and make executable
shell: bash
if: ${{ runner.os != 'Windows' }}
working-directory: ${{ inputs.path }}
run: |
tar xvf criticalup-${{ matrix.target }}.tar.xz
mv criticalup-${{ matrix.target }}/criticalup criticalup
chmod +x ./criticalup

- name: Auth Criticalup
shell: bash
working-directory: ${{ inputs.path }}
run: ./criticalup auth set $CRITICALUP_TOKEN

- name: Install toolchain
shell: bash
working-directory: ${{ inputs.path }}
run: |
./criticalup install

- name: Create toolchain link
shell: bash
working-directory: ${{ inputs.path }}
run: |
./criticalup link create

- name: Run `criticalup run` test workflow
shell: bash
working-directory: ${{ inputs.path }}
run: |
# We cannot run cargo init, it is an existing project
./criticalup run -- cargo build
./criticalup run -- cargo run --bin criticalup help
./criticalup which rustc

# Windows allows the `.exe` or not at the users option.
- name: Run Windows exclusive commands
shell: bash
if: ${{ runner.os == 'Windows' }}
working-directory: ${{ inputs.path }}
run: |
./criticalup.exe run -- cargo --version
./criticalup run -- cargo.exe --version
./criticalup.exe run -- cargo.exe --version

- name: Run `cargo +ferrocene` test workflow
shell: bash
working-directory: ${{ inputs.path }}
run: |
cargo +ferrocene build
cargo +ferrocene run --bin criticalup help

- name: Remove toolchain link
shell: bash
working-directory: ${{ inputs.path }}
run: |
./criticalup link remove

- name: Run test cleanup workflow
shell: bash
working-directory: ${{ inputs.path }}
run: |
./criticalup remove
./criticalup clean
123 changes: 66 additions & 57 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -74,74 +74,83 @@ jobs:
]
EOF

- uses: actions/download-artifact@v4
with:
name: criticalup-${{ matrix.target }}.${{ runner.os == 'Windows' && 'zip' || 'tar.xz' }}
path: crab-boil

- name: Unpack archive
if: ${{ runner.os == 'Windows' }}
working-directory: crab-boil
- name: Establish paths inside workflow before calling action
shell: bash
run: |
powershell -c "Expand-Archive criticalup-${{ matrix.target }}.zip"
mv criticalup-${{ matrix.target }}/criticalup.exe criticalup.exe

- name: Unpack archive and make executable
if: ${{ runner.os != 'Windows' }}
working-directory: crab-boil
run: |
tar xvf criticalup-${{ matrix.target }}.tar.xz
mv criticalup-${{ matrix.target }}/criticalup criticalup
chmod +x ./criticalup

- name: Auth Criticalup
working-directory: crab-boil
run: ./criticalup auth set $CRITICALUP_TOKEN
echo "pwd $(pwd)"
echo "github.workspace: ${{ github.workspace }}"
echo "runner.temp: ${{ runner.temp }}"
echo "GITHUB_WORKSPACE: $GITHUB_WORKSPACE"
echo "runner temp env variable $RUNNER_TEMP"


- name: Install toolchain
working-directory: crab-boil
run: |
./criticalup install

- name: Create toolchain link
working-directory: crab-boil
run: |
./criticalup link create

- name: Run `criticalup run` test workflow
working-directory: crab-boil
run: |
./criticalup run -- cargo init
./criticalup run -- cargo build
./criticalup run -- cargo run
./criticalup which rustc

# Windows allows the `.exe` or not, at the users option.
- name: Run Windows exclusive commands
if: ${{ runner.os == 'Windows' }}
working-directory: crab-boil
- name: Configure directory
uses: ./.github/actions/criticalup-config
with:
token: ${{ secrets.CRITICALUP_TOKEN }}
path: crab-boil
matrix: ${{ toJSON(matrix) }}
runner: ${{ toJSON(runner) }}

- name: Establish paths inside workflow after calling action
shell: bash
run: |
./criticalup.exe run -- cargo --version
./criticalup run -- cargo.exe --version
./criticalup.exe run -- cargo.exe --version
echo "pwd $(pwd)"
echo "github.workspace: ${{ github.workspace }}"
echo "runner.temp: ${{ runner.temp }}"
echo "GITHUB_WORKSPACE: $GITHUB_WORKSPACE"
echo "runner temp env variable $RUNNER_TEMP"

- name: Run `cargo +ferrocene` test workflow
- name: Test criticalup is still installed current dir
working-directory: crab-boil
run: ./criticalup help

- name: Change toolchain and dir to test RA installation
shell: bash # bash necessary for heredocs
run: |
cargo +ferrocene build
cargo +ferrocene run
mkdir poor-ferris
cd poor-ferris
cat <<- EOF > criticalup.toml
manifest-version = 1

- name: Remove toolchain link
working-directory: crab-boil
[products.ferrocene]
release = "nightly-2026-01-29"
packages = [
"cargo-\${rustc-host}",
"rustc-\${rustc-host}",
"rust-std-\${rustc-host}",
"rust-analyzer-\${rustc-host}"
]
EOF
- name: Rust-toolchain file
working-directory: poor-ferris
shell: bash
run: |
./criticalup link remove
cat <<- EOF > rust-toolchain.toml
[toolchain]
channel = "ferrocene"
components = ["cargo", "rustfmt", "clippy", "rust-analyzer"]
profile = "default"
EOF

- name: Run test cleanup workflow
working-directory: crab-boil
- name: Configure directory
uses: ./.github/actions/criticalup-config
with:
token: ${{ secrets.CRITICALUP_TOKEN }}
path: poor-ferris
matrix: ${{ toJSON(matrix) }}
runner: ${{ toJSON(runner) }}

- name: Test RA installation
shell: bash # bash necessary for heredocs
working-directory: poor-ferris
run: |
./criticalup remove
./criticalup clean
echo ${{ github.workspace }}
./criticalup install --reinstall
./criticalup link create # linking rust-analyzer
./criticalup which rust-analyzer
which rust-analyzer
rust-analyzer --version

package:
secrets: inherit
Expand Down
1 change: 0 additions & 1 deletion crates/criticalup-cli/tests/cli/binary_proxies.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@

use crate::assert_output;
use crate::utils::TestEnvironment;
use std::env;
use std::io::Write;
use std::path::{Path, PathBuf};
use std::process::{Command, Stdio};
Expand Down