From 426e06d0775ee5e42efa637b577ad33f990b1cd8 Mon Sep 17 00:00:00 2001 From: Kubaryt Date: Wed, 27 Aug 2025 17:23:42 +0200 Subject: [PATCH 01/23] enhancement: Add option to specify rust-toolchain.toml path (#47) --- README.md | 1 + action.yml | 9 ++++++++- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 6c7ca03..bd3fb9d 100644 --- a/README.md +++ b/README.md @@ -66,6 +66,7 @@ Afterward, the `components` and `target` specified via inputs are installed in a | `matcher` | Enable problem matcher to surface build messages and formatting issues | true | | `rustflags` | Set the value of `RUSTFLAGS` (set to empty string to avoid overwriting existing flags) | "-D warnings" | | `override` | Setup the last installed toolchain as the default via `rustup override` | true | +| `rust-toolchain-dir` | Path from root directory to directory with the rust toolchain file (if its not in the root of the repository) | | [`Swatinem/rust-cache`]: https://github.com/Swatinem/rust-cache diff --git a/action.yml b/action.yml index 328965d..0841e54 100644 --- a/action.yml +++ b/action.yml @@ -69,6 +69,9 @@ inputs: description: "Setup the last installed toolchain as the default via `rustup override`" required: false default: "true" + rust-toolchain-dir: + description: "Specify path from root directory to the directory to search for rust-toolchain.toml file. By default root directory will be used." + required: false outputs: rustc-version: @@ -163,14 +166,18 @@ runs: targets: ${{inputs.target}} components: ${{inputs.components}} override: ${{inputs.override}} + rust_toolchain_dir: ${{inputs.rust-toolchain-dir}} shell: bash run: | - if [[ -z "$toolchain" && ( -f "rust-toolchain" || -f "rust-toolchain.toml" ) ]] + if [[ -z "$toolchain" && ( -f "rust-toolchain" || -f "rust-toolchain.toml" || -f "$rust_toolchain_dir/rust-toolchain.toml") ]] then # Install the toolchain as specified in the file # rustup show is the old way that implicitly installed a toolchain # rustup toolchain install is the new explicit way # https://github.com/rust-lang/rustup/issues/3635#issuecomment-2343511297 + if [[ -n "$rust_toolchain_dir" ]]; then + cd "$rust_toolchain_dir" + fi rustup show active-toolchain || rustup toolchain install if [[ -n $components ]]; then rustup component add ${components//,/ } From 40ca8509269f7fa39a238ea71303b427ca538f31 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 28 Aug 2025 01:51:01 +0000 Subject: [PATCH 02/23] Bump actions/checkout from 4 to 5 Bumps [actions/checkout](https://github.com/actions/checkout) from 4 to 5. - [Release notes](https://github.com/actions/checkout/releases) - [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md) - [Commits](https://github.com/actions/checkout/compare/v4...v5) --- updated-dependencies: - dependency-name: actions/checkout dependency-version: '5' dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- .github/workflows/autotag-releases.yml | 2 +- .github/workflows/ci.yml | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/autotag-releases.yml b/.github/workflows/autotag-releases.yml index 4ca4ad5..b909f17 100644 --- a/.github/workflows/autotag-releases.yml +++ b/.github/workflows/autotag-releases.yml @@ -15,7 +15,7 @@ jobs: permissions: contents: write steps: - - uses: actions/checkout@v4 + - uses: actions/checkout@v5 - name: Get version from tag id: tag_name run: | diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index a2d5ed9..d498fb2 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -32,7 +32,7 @@ jobs: - "beta" - "stable" steps: - - uses: actions/checkout@v4 + - uses: actions/checkout@v5 # Test toolchain file support - name: Write rust-toolchain.toml @@ -93,7 +93,7 @@ jobs: name: Cache runs-on: ubuntu-latest steps: - - uses: actions/checkout@v4 + - uses: actions/checkout@v5 - name: Install Rust uses: ./ From 0be57f121b446537240d2226d940ec5fcc8c5788 Mon Sep 17 00:00:00 2001 From: Kubaryt Date: Thu, 28 Aug 2025 14:14:08 +0200 Subject: [PATCH 03/23] combine rust-src-dir presence and rust_toolchain file presence checks --- README.md | 2 +- action.yml | 14 +++++++------- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/README.md b/README.md index bd3fb9d..44fb937 100644 --- a/README.md +++ b/README.md @@ -66,7 +66,7 @@ Afterward, the `components` and `target` specified via inputs are installed in a | `matcher` | Enable problem matcher to surface build messages and formatting issues | true | | `rustflags` | Set the value of `RUSTFLAGS` (set to empty string to avoid overwriting existing flags) | "-D warnings" | | `override` | Setup the last installed toolchain as the default via `rustup override` | true | -| `rust-toolchain-dir` | Path from root directory to directory with the rust toolchain file (if its not in the root of the repository) | | +| `rust-src-dir` | Path from root directory to directory with the Rust source directory (if its not in the root of the repository) | | [`Swatinem/rust-cache`]: https://github.com/Swatinem/rust-cache diff --git a/action.yml b/action.yml index 0841e54..44509ee 100644 --- a/action.yml +++ b/action.yml @@ -69,8 +69,8 @@ inputs: description: "Setup the last installed toolchain as the default via `rustup override`" required: false default: "true" - rust-toolchain-dir: - description: "Specify path from root directory to the directory to search for rust-toolchain.toml file. By default root directory will be used." + rust-src-dir: + description: "Specify path from root directory to the Rust source directory. By default root directory will be used." required: false outputs: @@ -166,18 +166,18 @@ runs: targets: ${{inputs.target}} components: ${{inputs.components}} override: ${{inputs.override}} - rust_toolchain_dir: ${{inputs.rust-toolchain-dir}} + rust_src_dir: ${{inputs.rust-src-dir}} shell: bash run: | - if [[ -z "$toolchain" && ( -f "rust-toolchain" || -f "rust-toolchain.toml" || -f "$rust_toolchain_dir/rust-toolchain.toml") ]] + if [[ -d "$rust_src_dir" ]]; then + cd "$rust_src_dir" + fi + if [[ -z "$toolchain" && ( -f "rust-toolchain" || -f "rust-toolchain.toml") ]] then # Install the toolchain as specified in the file # rustup show is the old way that implicitly installed a toolchain # rustup toolchain install is the new explicit way # https://github.com/rust-lang/rustup/issues/3635#issuecomment-2343511297 - if [[ -n "$rust_toolchain_dir" ]]; then - cd "$rust_toolchain_dir" - fi rustup show active-toolchain || rustup toolchain install if [[ -n $components ]]; then rustup component add ${components//,/ } From 4222ef94871f3f698810eb62707fe867150eec6a Mon Sep 17 00:00:00 2001 From: Kubaryt Date: Thu, 28 Aug 2025 14:18:08 +0200 Subject: [PATCH 04/23] Set workspaces in `Swatinem/rust-cache` to rust-src-dir if cache-workspaces is not set --- action.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/action.yml b/action.yml index 44509ee..35e0d30 100644 --- a/action.yml +++ b/action.yml @@ -229,7 +229,7 @@ runs: if: inputs.cache == 'true' uses: Swatinem/rust-cache@v2 with: - workspaces: ${{inputs.cache-workspaces}} + workspaces: ${{ inputs.cache-workspaces || inputs.rust-src-dir }} cache-directories: ${{inputs.cache-directories}} cache-on-failure: ${{inputs.cache-on-failure}} cache-bin: ${{inputs.cache-bin}} From fd2478fbf0eb4ca9382053f3ce41f8da9cb2683f Mon Sep 17 00:00:00 2001 From: martinfrances107 Date: Wed, 3 Sep 2025 18:58:19 +0100 Subject: [PATCH 05/23] README should direct users to actions/checkout@5. --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 6c7ca03..5422c43 100644 --- a/README.md +++ b/README.md @@ -21,7 +21,7 @@ jobs: name: cargo test runs-on: ubuntu-latest steps: - - uses: actions/checkout@v4 + - uses: actions/checkout@v5 - uses: actions-rust-lang/setup-rust-toolchain@v1 - run: cargo test --all-features @@ -30,7 +30,7 @@ jobs: name: cargo fmt runs-on: ubuntu-latest steps: - - uses: actions/checkout@v4 + - uses: actions/checkout@v5 # Ensure rustfmt is installed and setup problem matcher - uses: actions-rust-lang/setup-rust-toolchain@v1 with: From 2fcdc490d667999e01ddbbf0f2823181beef6b39 Mon Sep 17 00:00:00 2001 From: Jonas Bushart Date: Sun, 14 Sep 2025 21:49:03 +0200 Subject: [PATCH 06/23] Update readme and changelog for 1.15.0 --- CHANGELOG.md | 6 ++++++ README.md | 38 +++++++++++++++++++------------------- 2 files changed, 25 insertions(+), 19 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index b302a9c..fbf8b7c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,6 +7,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [Unreleased] +## [1.15.0] - 2025-09-14 + +* Add support for non-root source directory. + Accept source code and `rust-toolchain.toml` file in subdirectories of the repository. + Adds a new parameter `rust-src-dir` that controls the lookup for toolchain files and sets a default value for the `cache-workspace` input. (#69 by @Kubaryt) + ## [1.14.1] - 2025-08-28 * Pin `Swatinem/rust-cache` action to a full commit SHA (#68 by @JohnTitor) diff --git a/README.md b/README.md index 7051aa4..c4f588e 100644 --- a/README.md +++ b/README.md @@ -48,25 +48,25 @@ If no `toolchain` value or toolchain file is present, it will default to `stable First, all items specified in the toolchain file are installed. Afterward, the `components` and `target` specified via inputs are installed in addition to the items from the toolchain file. -| Name | Description | Default | -| ------------------------ | ----------------------------------------------------------------------------------------------------------------------- | ------------- | -| `toolchain` | Comma-separated list of Rustup toolchain specifier e.g. `stable`, `nightly`, `1.42.0`. The last version is the default. | stable | -| `target` | Additional target support to install e.g. `wasm32-unknown-unknown` | | -| `components` | Comma-separated string of additional components to install e.g. `clippy, rustfmt` | | -| `cache` | Automatically configure Rust cache (using [`Swatinem/rust-cache`]) | true | -| `cache-directories` | Propagates the value to [`Swatinem/rust-cache`] | | -| `cache-workspaces` | Propagates the value to [`Swatinem/rust-cache`] | | -| `cache-on-failure` | Propagates the value to [`Swatinem/rust-cache`] | true | -| `cache-key` | Propagates the value to [`Swatinem/rust-cache`] as `key` | | -| `cache-shared-key` | Propagates the value to [`Swatinem/rust-cache`] as `shared-key` | | -| `cache-bin` | Propagates the value to [`Swatinem/rust-cache`] as `cache-bin` | true | -| `cache-provider` | Propagates the value to [`Swatinem/rust-cache`] as `cache-provider` | 'github' | -| `cache-all-crates` | Propagates the value to [`Swatinem/rust-cache`] as `cache-all-crates` | false | -| `cache-workspace-crates` | Propagates the value to [`Swatinem/rust-cache`] as `cache-workspace-crates` | false | -| `matcher` | Enable problem matcher to surface build messages and formatting issues | true | -| `rustflags` | Set the value of `RUSTFLAGS` (set to empty string to avoid overwriting existing flags) | "-D warnings" | -| `override` | Setup the last installed toolchain as the default via `rustup override` | true | -| `rust-src-dir` | Path from root directory to directory with the Rust source directory (if its not in the root of the repository) | | +| Name | Description | Default | +| ------------------------ | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------- | +| `toolchain` | Comma-separated list of Rustup toolchain specifier e.g. `stable`, `nightly`, `1.42.0`. The last version is the default. | stable | +| `target` | Additional target support to install e.g. `wasm32-unknown-unknown` | | +| `components` | Comma-separated string of additional components to install e.g. `clippy, rustfmt` | | +| `cache` | Automatically configure Rust cache (using [`Swatinem/rust-cache`]) | true | +| `cache-directories` | Propagates the value to [`Swatinem/rust-cache`] | | +| `cache-workspaces` | Propagates the value to [`Swatinem/rust-cache`]. Influenced by the value of `rust-src-dir`. | | +| `cache-on-failure` | Propagates the value to [`Swatinem/rust-cache`] | true | +| `cache-key` | Propagates the value to [`Swatinem/rust-cache`] as `key` | | +| `cache-shared-key` | Propagates the value to [`Swatinem/rust-cache`] as `shared-key` | | +| `cache-bin` | Propagates the value to [`Swatinem/rust-cache`] as `cache-bin` | true | +| `cache-provider` | Propagates the value to [`Swatinem/rust-cache`] as `cache-provider` | 'github' | +| `cache-all-crates` | Propagates the value to [`Swatinem/rust-cache`] as `cache-all-crates` | false | +| `cache-workspace-crates` | Propagates the value to [`Swatinem/rust-cache`] as `cache-workspace-crates` | false | +| `matcher` | Enable problem matcher to surface build messages and formatting issues | true | +| `rustflags` | Set the value of `RUSTFLAGS` (set to empty string to avoid overwriting existing flags) | "-D warnings" | +| `override` | Setup the last installed toolchain as the default via `rustup override` | true | +| `rust-src-dir` | Path from root directory to directory with the Rust source directory (if its not in the root of the repository). Sets a default value for `cache-workspaces` that enables caching. | | [`Swatinem/rust-cache`]: https://github.com/Swatinem/rust-cache From 183cfebcbd070909e5077c3b4a44326e8e8418f5 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 22 Sep 2025 07:02:11 +0000 Subject: [PATCH 07/23] Bump Swatinem/rust-cache from 2.8.0 to 2.8.1 Bumps [Swatinem/rust-cache](https://github.com/swatinem/rust-cache) from 2.8.0 to 2.8.1. - [Release notes](https://github.com/swatinem/rust-cache/releases) - [Changelog](https://github.com/Swatinem/rust-cache/blob/master/CHANGELOG.md) - [Commits](https://github.com/swatinem/rust-cache/compare/98c8021b550208e191a6a3145459bfc9fb29c4c0...f13886b937689c021905a6b90929199931d60db1) --- updated-dependencies: - dependency-name: Swatinem/rust-cache dependency-version: 2.8.1 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- action.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/action.yml b/action.yml index 7f33d91..adfaf9b 100644 --- a/action.yml +++ b/action.yml @@ -227,7 +227,7 @@ runs: - name: Setup Rust Caching if: inputs.cache == 'true' - uses: Swatinem/rust-cache@98c8021b550208e191a6a3145459bfc9fb29c4c0 # v2.8.0 + uses: Swatinem/rust-cache@f13886b937689c021905a6b90929199931d60db1 # v2.8.1 with: workspaces: ${{ inputs.cache-workspaces || inputs.rust-src-dir }} cache-directories: ${{inputs.cache-directories}} From 02be93da58aa71fb456aa9c43b301149248829d8 Mon Sep 17 00:00:00 2001 From: Jonas Bushart Date: Tue, 23 Sep 2025 22:16:00 +0200 Subject: [PATCH 08/23] Update `Swatinem/rust-cache` to v2.8.1 --- CHANGELOG.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index fbf8b7c..61c54a0 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,6 +7,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [Unreleased] +## [1.15.1] - 2025-09-23 + +* Update `Swatinem/rust-cache` to v2.8.1 + ## [1.15.0] - 2025-09-14 * Add support for non-root source directory. From d6688fbd7ac5ea1b5a36f14397b1b3478b230b3d Mon Sep 17 00:00:00 2001 From: Jonas Bushart Date: Fri, 3 Oct 2025 23:23:33 +0200 Subject: [PATCH 09/23] Print an error and exit if 'rust-src-dir' does not point to an existing directory --- action.yml | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/action.yml b/action.yml index adfaf9b..732335f 100644 --- a/action.yml +++ b/action.yml @@ -171,6 +171,10 @@ runs: run: | if [[ -d "$rust_src_dir" ]]; then cd "$rust_src_dir" + else + echo "'rust-src-dir' does not point to an existing directory" >&2 + echo "The value of 'rust-src-dir' is: ${rust_src_dir}" >&2 + exit 1 fi if [[ -z "$toolchain" && ( -f "rust-toolchain" || -f "rust-toolchain.toml") ]] then @@ -201,7 +205,12 @@ runs: - id: versions name: Print installed versions shell: bash + env: + rust_src_dir: ${{inputs.rust-src-dir}} run: | + # Switch to the selected sub-directory for + cd "$rust_src_dir" + echo "rustc-version=$(rustc --version)" >> $GITHUB_OUTPUT rustc --version --verbose echo "cargo-version=$(cargo --version)" >> $GITHUB_OUTPUT From 51897173ae78adacb4740d26e586bb68ca7280a0 Mon Sep 17 00:00:00 2001 From: Jonas Bushart Date: Sat, 4 Oct 2025 12:57:01 +0200 Subject: [PATCH 10/23] Gate the rust-src-dir check by first checking if the value is set --- action.yml | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) diff --git a/action.yml b/action.yml index 732335f..1f56cd2 100644 --- a/action.yml +++ b/action.yml @@ -169,12 +169,18 @@ runs: rust_src_dir: ${{inputs.rust-src-dir}} shell: bash run: | - if [[ -d "$rust_src_dir" ]]; then - cd "$rust_src_dir" - else - echo "'rust-src-dir' does not point to an existing directory" >&2 - echo "The value of 'rust-src-dir' is: ${rust_src_dir}" >&2 - exit 1 + # Check if value is set + if [[ -n "$rust_src_dir" ]] + then + # If value is set the directory must exist + if [[ -d "$rust_src_dir" ]] + then + cd "$rust_src_dir" + else + echo "'rust-src-dir' does not point to an existing directory" >&2 + echo "The value of 'rust-src-dir' is: ${rust_src_dir}" >&2 + exit 1 + fi fi if [[ -z "$toolchain" && ( -f "rust-toolchain" || -f "rust-toolchain.toml") ]] then From f89a8066919b33227a8589aa2b9e4cfa88ad1691 Mon Sep 17 00:00:00 2001 From: Jonas Bushart Date: Sat, 4 Oct 2025 13:06:57 +0200 Subject: [PATCH 11/23] Use the built-in working-directory selector and default to "." if rust-src-dir is not set --- action.yml | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/action.yml b/action.yml index 1f56cd2..edccc6b 100644 --- a/action.yml +++ b/action.yml @@ -211,12 +211,9 @@ runs: - id: versions name: Print installed versions shell: bash - env: - rust_src_dir: ${{inputs.rust-src-dir}} + # Switch to the Rust sub-directory + working-directory: ${{inputs.rust-src-dir || "."}} run: | - # Switch to the selected sub-directory for - cd "$rust_src_dir" - echo "rustc-version=$(rustc --version)" >> $GITHUB_OUTPUT rustc --version --verbose echo "cargo-version=$(cargo --version)" >> $GITHUB_OUTPUT From 063a3b947b5c5bf7d5f87076c3e5e9784b776aa8 Mon Sep 17 00:00:00 2001 From: Jonas Bushart Date: Sat, 4 Oct 2025 13:10:09 +0200 Subject: [PATCH 12/23] Use correct quoting style for working-directory --- action.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/action.yml b/action.yml index edccc6b..2a12f0b 100644 --- a/action.yml +++ b/action.yml @@ -212,7 +212,7 @@ runs: name: Print installed versions shell: bash # Switch to the Rust sub-directory - working-directory: ${{inputs.rust-src-dir || "."}} + working-directory: ${{inputs.rust-src-dir || '.'}} run: | echo "rustc-version=$(rustc --version)" >> $GITHUB_OUTPUT rustc --version --verbose From 1780873c7b576612439a134613cc4cc74ce5538c Mon Sep 17 00:00:00 2001 From: Jonas Bushart Date: Sat, 4 Oct 2025 15:50:05 +0200 Subject: [PATCH 13/23] Fix: Run the version detection steps in the selected `rust-src-dir` directory. This should enable the version selection even without a default toolchain installed. Fixes #74. --- CHANGELOG.md | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 61c54a0..14857f5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,6 +7,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [Unreleased] +## [1.15.2] - 2025-10-04 + +* Fix: Run the version detection steps in the selected `rust-src-dir` directory. + This should enable the version selection even without a default toolchain installed. + Fixes #74. + ## [1.15.1] - 2025-09-23 * Update `Swatinem/rust-cache` to v2.8.1 From c103666ab0e01f766d777b5464cd974d8ca1f711 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 24 Nov 2025 07:02:51 +0000 Subject: [PATCH 14/23] Bump actions/checkout from 5 to 6 Bumps [actions/checkout](https://github.com/actions/checkout) from 5 to 6. - [Release notes](https://github.com/actions/checkout/releases) - [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md) - [Commits](https://github.com/actions/checkout/compare/v5...v6) --- updated-dependencies: - dependency-name: actions/checkout dependency-version: '6' dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- .github/workflows/autotag-releases.yml | 2 +- .github/workflows/ci.yml | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/autotag-releases.yml b/.github/workflows/autotag-releases.yml index b909f17..1763a52 100644 --- a/.github/workflows/autotag-releases.yml +++ b/.github/workflows/autotag-releases.yml @@ -15,7 +15,7 @@ jobs: permissions: contents: write steps: - - uses: actions/checkout@v5 + - uses: actions/checkout@v6 - name: Get version from tag id: tag_name run: | diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index d498fb2..810cf8e 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -32,7 +32,7 @@ jobs: - "beta" - "stable" steps: - - uses: actions/checkout@v5 + - uses: actions/checkout@v6 # Test toolchain file support - name: Write rust-toolchain.toml @@ -93,7 +93,7 @@ jobs: name: Cache runs-on: ubuntu-latest steps: - - uses: actions/checkout@v5 + - uses: actions/checkout@v6 - name: Install Rust uses: ./ From e541adf9901fbab8b9379aee33a999f5cd02a33d Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 1 Dec 2025 09:13:07 +0000 Subject: [PATCH 15/23] Bump Swatinem/rust-cache from 2.8.1 to 2.8.2 Bumps [Swatinem/rust-cache](https://github.com/swatinem/rust-cache) from 2.8.1 to 2.8.2. - [Release notes](https://github.com/swatinem/rust-cache/releases) - [Changelog](https://github.com/Swatinem/rust-cache/blob/master/CHANGELOG.md) - [Commits](https://github.com/swatinem/rust-cache/compare/f13886b937689c021905a6b90929199931d60db1...779680da715d629ac1d338a641029a2f4372abb5) --- updated-dependencies: - dependency-name: Swatinem/rust-cache dependency-version: 2.8.2 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- action.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/action.yml b/action.yml index 2a12f0b..33fb935 100644 --- a/action.yml +++ b/action.yml @@ -239,7 +239,7 @@ runs: - name: Setup Rust Caching if: inputs.cache == 'true' - uses: Swatinem/rust-cache@f13886b937689c021905a6b90929199931d60db1 # v2.8.1 + uses: Swatinem/rust-cache@779680da715d629ac1d338a641029a2f4372abb5 # v2.8.2 with: workspaces: ${{ inputs.cache-workspaces || inputs.rust-src-dir }} cache-directories: ${{inputs.cache-directories}} From 806aa7ddf5d59f36fb30048411f6bde29364a53f Mon Sep 17 00:00:00 2001 From: Jonas Bushart Date: Wed, 24 Dec 2025 21:24:20 +0200 Subject: [PATCH 16/23] Add dependabot cooldown This limits how quickly new dependencies are considered for updates. --- .github/dependabot.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/dependabot.yml b/.github/dependabot.yml index 92c44a8..a3f176c 100644 --- a/.github/dependabot.yml +++ b/.github/dependabot.yml @@ -9,3 +9,5 @@ updates: directory: "/" schedule: interval: "weekly" + cooldown: + default-days: 7 From a0004163461e62eec251aed6b418efc614375db3 Mon Sep 17 00:00:00 2001 From: xtqqczze <45661989+xtqqczze@users.noreply.github.com> Date: Thu, 29 Jan 2026 02:23:16 +0000 Subject: [PATCH 17/23] Add .gitignore to exclude `test-workspace/target/` --- .gitignore | 1 + 1 file changed, 1 insertion(+) create mode 100644 .gitignore diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..d922da4 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +test-workspace/target/ From a0b538fa0b742a6aa35d6e2c169b4bd06d225a98 Mon Sep 17 00:00:00 2001 From: Jonas Bushart Date: Sun, 1 Mar 2026 00:12:34 +0100 Subject: [PATCH 18/23] Update changelog --- CHANGELOG.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 14857f5..010f97a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,6 +7,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [Unreleased] +## [1.15.3] - 2026-03-01 + +* Bump Swatinem/rust-cache from 2.8.1 to 2.8.2 + ## [1.15.2] - 2025-10-04 * Fix: Run the version detection steps in the selected `rust-src-dir` directory. From 229ed076e84b5b65cd2f9d73f942027b40c35131 Mon Sep 17 00:00:00 2001 From: Takuma IMAMURA <209989118+hyperfinitism@users.noreply.github.com> Date: Sun, 15 Mar 2026 05:12:39 +0900 Subject: [PATCH 19/23] deps: Bump Swatinem/rust-cache from 2.8.2 to 2.9.1 Update rust-cache to v2.9.1 to migrate from Node.js 20 to Node.js 24. Node.js 20 reaches EoL at the end of April 2026. Signed-off-by: Takuma IMAMURA <209989118+hyperfinitism@users.noreply.github.com> --- action.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/action.yml b/action.yml index 33fb935..ee1e79f 100644 --- a/action.yml +++ b/action.yml @@ -239,7 +239,7 @@ runs: - name: Setup Rust Caching if: inputs.cache == 'true' - uses: Swatinem/rust-cache@779680da715d629ac1d338a641029a2f4372abb5 # v2.8.2 + uses: Swatinem/rust-cache@c19371144df3bb44fab255c43d04cbc2ab54d1c4 # v2.9.1 with: workspaces: ${{ inputs.cache-workspaces || inputs.rust-src-dir }} cache-directories: ${{inputs.cache-directories}} From 150fca883cd4034361b621bd4e6a9d34e5143606 Mon Sep 17 00:00:00 2001 From: Jonas Bushart Date: Sun, 15 Mar 2026 00:49:10 +0100 Subject: [PATCH 20/23] Update CHANGELOG for version 1.15.4 Added release notes for version 1.15.4, including dependency updates. --- CHANGELOG.md | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 010f97a..00858fe 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,6 +7,11 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [Unreleased] +## [1.15.4] - 2026-03-15 + +* Bump Swatinem/rust-cache from 2.8.2 to 2.9.1 (#87 by @hyperfinitism) + This gets rid of the warnings about Node.js 20. + ## [1.15.3] - 2026-03-01 * Bump Swatinem/rust-cache from 2.8.1 to 2.8.2 From fa057b45cfd520ccd3ca4d2ae31c5abdaa2e855d Mon Sep 17 00:00:00 2001 From: Ryu <114303361+ryuapp@users.noreply.github.com> Date: Sun, 22 Mar 2026 12:17:35 +0900 Subject: [PATCH 21/23] Update actions/checkout to v6 on README --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index c4f588e..5bd87e7 100644 --- a/README.md +++ b/README.md @@ -21,7 +21,7 @@ jobs: name: cargo test runs-on: ubuntu-latest steps: - - uses: actions/checkout@v5 + - uses: actions/checkout@v6 - uses: actions-rust-lang/setup-rust-toolchain@v1 - run: cargo test --all-features @@ -30,7 +30,7 @@ jobs: name: cargo fmt runs-on: ubuntu-latest steps: - - uses: actions/checkout@v5 + - uses: actions/checkout@v6 # Ensure rustfmt is installed and setup problem matcher - uses: actions-rust-lang/setup-rust-toolchain@v1 with: From 186b99ef06deaa18471fe4efa80002511ebb0617 Mon Sep 17 00:00:00 2001 From: ChanTsune <41658782+ChanTsune@users.noreply.github.com> Date: Sat, 11 Apr 2026 23:32:14 +0900 Subject: [PATCH 22/23] feat: add cache-save-if input to propagate save-if to Swatinem/rust-cache --- README.md | 1 + action.yml | 5 +++++ 2 files changed, 6 insertions(+) diff --git a/README.md b/README.md index 5bd87e7..7f1cb43 100644 --- a/README.md +++ b/README.md @@ -63,6 +63,7 @@ Afterward, the `components` and `target` specified via inputs are installed in a | `cache-provider` | Propagates the value to [`Swatinem/rust-cache`] as `cache-provider` | 'github' | | `cache-all-crates` | Propagates the value to [`Swatinem/rust-cache`] as `cache-all-crates` | false | | `cache-workspace-crates` | Propagates the value to [`Swatinem/rust-cache`] as `cache-workspace-crates` | false | +| `cache-save-if` | Propagates the value to [`Swatinem/rust-cache`] as `save-if` | true | | `matcher` | Enable problem matcher to surface build messages and formatting issues | true | | `rustflags` | Set the value of `RUSTFLAGS` (set to empty string to avoid overwriting existing flags) | "-D warnings" | | `override` | Setup the last installed toolchain as the default via `rustup override` | true | diff --git a/action.yml b/action.yml index ee1e79f..df428d4 100644 --- a/action.yml +++ b/action.yml @@ -57,6 +57,10 @@ inputs: description: "Determines which crates are cached. If `true` all crates will be cached, otherwise only dependent crates will be cached." required: false default: "false" + cache-save-if: + description: "Determines whether the cache should be saved. If `false`, the cache is only restored." + required: false + default: "true" matcher: description: "Enable the Rust problem matcher" required: false @@ -248,5 +252,6 @@ runs: cache-provider: ${{inputs.cache-provider}} cache-all-crates: ${{inputs.cache-all-crates}} cache-workspace-crates: ${{inputs.cache-workspace-crates}} + save-if: ${{inputs.cache-save-if}} key: ${{inputs.cache-key}} shared-key: ${{inputs.cache-shared-key}} From 2b1f5e9b395427c92ee4e3331786ca3c37afe2d7 Mon Sep 17 00:00:00 2001 From: Jonas Bushart Date: Mon, 13 Apr 2026 21:33:09 +0200 Subject: [PATCH 23/23] Update CHANGELOG for version 1.16.0 Add release notes for version 1.16.0 including new parameter. --- CHANGELOG.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 00858fe..91695a6 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,6 +7,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [Unreleased] +## [1.16.0] - 2026-04-13 + +* Add new parameter `cache-save-if` that is propagated to `Swatinem/rust-cache` as `save-if` (#90 by @ChanTsune) + ## [1.15.4] - 2026-03-15 * Bump Swatinem/rust-cache from 2.8.2 to 2.9.1 (#87 by @hyperfinitism)