Skip to content
This repository was archived by the owner on May 28, 2025. It is now read-only.

Commit 40306ba

Browse files
committed
Auto merge of rust-lang#2175 - RalfJung:xargo, r=oli-obk
bump Xargo Also use that as a clue to refresh our CI caches. Fixes rust-lang/miri#705
2 parents f7c1b5b + 4f70093 commit 40306ba

File tree

3 files changed

+10
-5
lines changed

3 files changed

+10
-5
lines changed

.github/workflows/ci.yml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,8 @@ jobs:
4646
# we cannot reuse anyway when the nightly changes (and it grows quite large
4747
# over time).
4848
- name: Add cache for cargo
49-
uses: actions/cache@v2
49+
id: cache
50+
uses: actions/cache@v3
5051
with:
5152
path: |
5253
# Taken from <https://doc.rust-lang.org/nightly/cargo/guide/cargo-home.html#caching-the-cargo-home-in-ci>.
@@ -57,10 +58,11 @@ jobs:
5758
# contains package information of crates installed via `cargo install`.
5859
~/.cargo/.crates.toml
5960
~/.cargo/.crates2.json
60-
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}-xargo0.3.25
61+
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock', 'cargo-miri/version.rs') }}
6162
restore-keys: ${{ runner.os }}-cargo
6263

6364
- name: Install rustup-toolchain-install-master and xargo
65+
if: ${{ steps.cache.outputs.cache-hit == 'false' }}
6466
shell: bash
6567
run: |
6668
cargo install rustup-toolchain-install-master

cargo-miri/bin.rs

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
mod version;
2+
13
use std::env;
24
use std::ffi::{OsStr, OsString};
35
use std::fmt::Write as _;
@@ -8,11 +10,10 @@ use std::ops::Not;
810
use std::path::{Path, PathBuf};
911
use std::process::{self, Command};
1012

11-
use serde::{Deserialize, Serialize};
12-
1313
use rustc_version::VersionMeta;
14+
use serde::{Deserialize, Serialize};
1415

15-
const XARGO_MIN_VERSION: (u32, u32, u32) = (0, 3, 23);
16+
use version::*;
1617

1718
const CARGO_MIRI_HELP: &str = r#"Runs binary crates and tests in Miri
1819

cargo-miri/version.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
// We put this in a separate file so that it can be hashed for GHA caching.
2+
pub const XARGO_MIN_VERSION: (u32, u32, u32) = (0, 3, 26);

0 commit comments

Comments
 (0)