ci: Do not install cargo machete by building it (#53607)
Re-building the tool on CI every time is pointless when can just install the binary itself Release Notes: - N/A or Added/Fixed/Improved ...
This commit is contained in:
1 parent
0bba730c1e
commit
11cb9f4356
4 files changed
+15
-26
No files matched your search
@@ -45,10 +45,9 @@ jobs:
|
||||
version: '9'
|
||||
- name: autofix_pr::run_autofix::install_cargo_machete
|
||||
if: ${{ inputs.run_clippy }}
|
||||
uses: clechasseur/rs-cargo@8435b10f6e71c2e3d4d3b7573003a8ce4bfc6386
|
||||
uses: taiki-e/install-action@02cc5f8ca9f2301050c0c099055816a41ee05507
|
||||
with:
|
||||
command: install
|
||||
args: cargo-machete@0.7.0
|
||||
tool: cargo-machete@0.7.0
|
||||
- name: autofix_pr::run_autofix::run_cargo_fix
|
||||
if: ${{ inputs.run_clippy }}
|
||||
run: cargo fix --workspace --release --all-targets --all-features --allow-dirty --allow-staged
|
||||
|
||||
@@ -618,14 +618,11 @@ jobs:
|
||||
cache: rust
|
||||
path: ~/.rustup
|
||||
- name: run_tests::check_dependencies::install_cargo_machete
|
||||
uses: clechasseur/rs-cargo@8435b10f6e71c2e3d4d3b7573003a8ce4bfc6386
|
||||
uses: taiki-e/install-action@02cc5f8ca9f2301050c0c099055816a41ee05507
|
||||
with:
|
||||
command: install
|
||||
args: cargo-machete@0.7.0
|
||||
tool: cargo-machete@0.7.0
|
||||
- name: run_tests::check_dependencies::run_cargo_machete
|
||||
uses: clechasseur/rs-cargo@8435b10f6e71c2e3d4d3b7573003a8ce4bfc6386
|
||||
with:
|
||||
command: machete
|
||||
run: cargo machete
|
||||
- name: run_tests::check_dependencies::check_cargo_lock
|
||||
run: cargo update --locked --workspace
|
||||
- name: run_tests::check_dependencies::check_vulnerable_dependencies
|
||||
|
||||
@@ -62,12 +62,11 @@ fn run_autofix(pr_number: &WorkflowInput, run_clippy: &WorkflowInput) -> NamedJo
|
||||
|
||||
fn install_cargo_machete() -> Step<Use> {
|
||||
named::uses(
|
||||
"clechasseur",
|
||||
"rs-cargo",
|
||||
"8435b10f6e71c2e3d4d3b7573003a8ce4bfc6386", // v2
|
||||
"taiki-e",
|
||||
"install-action",
|
||||
"02cc5f8ca9f2301050c0c099055816a41ee05507",
|
||||
)
|
||||
.add_with(("command", "install"))
|
||||
.add_with(("args", "cargo-machete@0.7.0"))
|
||||
.add_with(("tool", "cargo-machete@0.7.0"))
|
||||
}
|
||||
|
||||
fn run_cargo_fmt() -> Step<Run> {
|
||||
|
||||
@@ -408,21 +408,15 @@ fn check_style() -> NamedJob {
|
||||
fn check_dependencies() -> NamedJob {
|
||||
fn install_cargo_machete() -> Step<Use> {
|
||||
named::uses(
|
||||
"clechasseur",
|
||||
"rs-cargo",
|
||||
"8435b10f6e71c2e3d4d3b7573003a8ce4bfc6386", // v2
|
||||
"taiki-e",
|
||||
"install-action",
|
||||
"02cc5f8ca9f2301050c0c099055816a41ee05507",
|
||||
)
|
||||
.add_with(("command", "install"))
|
||||
.add_with(("args", "cargo-machete@0.7.0"))
|
||||
.add_with(("tool", "cargo-machete@0.7.0"))
|
||||
}
|
||||
|
||||
fn run_cargo_machete() -> Step<Use> {
|
||||
named::uses(
|
||||
"clechasseur",
|
||||
"rs-cargo",
|
||||
"8435b10f6e71c2e3d4d3b7573003a8ce4bfc6386", // v2
|
||||
)
|
||||
.add_with(("command", "machete"))
|
||||
fn run_cargo_machete() -> Step<Run> {
|
||||
named::bash("cargo machete")
|
||||
}
|
||||
|
||||
fn check_cargo_lock() -> Step<Run> {
|
||||
|
||||
Reference in new issue
Block a user