Skip to content

Commit

Permalink
build(deps): ➖ comment out unused deps, reduce build time
Browse files Browse the repository at this point in the history
  • Loading branch information
Jisu-Woniu committed Feb 14, 2024
1 parent 677cf90 commit 8440efa
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 81 deletions.
74 changes: 0 additions & 74 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

14 changes: 8 additions & 6 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -69,16 +69,18 @@ systemd-units = { enable = false }

[dependencies]
anyhow = "1.0.79"
cgroups = "0.1.0"
clap = { version = "4.5.0", features = ["derive"] }
duct = "0.13.7"
nix = { version = "0.27.1", features = ["fs"] }
rsjudge-runner = { version = "0.1.0", path = "crates/rsjudge-runner" }
serde = { version = "1.0.196", features = ["derive"] }
strfmt = "0.2.4"
tokio = { version = "1.36.0", features = ["fs"] }
toml = "0.8.10"
uzers = "0.11.3"

# Unused for now:
# cgroups = "0.1.0"
# duct = "0.13.7"
# nix = { version = "0.27.1", features = ["fs"] }
# strfmt = "0.2.4"
# tokio = { version = "1.36.0", features = ["fs"] }
# uzers = "0.11.3"

# Optional dependencies
rsjudge-grpc = { version = "0.1.0", path = "crates/rsjudge-grpc", optional = true }
Expand Down
4 changes: 3 additions & 1 deletion xtask/src/dist/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,8 @@ pub(crate) fn build_script_out_dir(sh: &Shell, profile: Profile) -> anyhow::Resu
.split_once("#")
.expect(&format!("Unexpected pkgid: {:?}", pkgid));

let pkg_pattern = format!("({})", pkgid.0);

let flag = profile.flag();

cmd!(sh, "cargo build --locked {flag...} --message-format=json")
Expand All @@ -53,7 +55,7 @@ pub(crate) fn build_script_out_dir(sh: &Shell, profile: Profile) -> anyhow::Resu
CargoCheckMessage::BuildScriptExecuted {
package_id,
out_dir,
} if package_id.ends_with(&format!("({})", pkgid.0)) => Some(out_dir),
} if package_id.ends_with(&pkg_pattern) => Some(out_dir),
_ => None,
}
})
Expand Down

0 comments on commit 8440efa

Please sign in to comment.