Skip to content

Commit 4256d02

Browse files
committed
Switch to cargo workspace
Primary: - Switch to cargo workspace to replace xtask, make, etc. - Add debug symbol stripping Misc: - Upgrade all packages - Replace entries iterator with "next" due to the following PR: rust-lang/git2-rs#854 - Remove "rustfmt.toml" Signed-off-by: Nick Gerace <[email protected]>
1 parent 012c20f commit 4256d02

22 files changed

+130
-109
lines changed

CHANGELOG.md

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,15 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
77

88
## [Unreleased]
99

10-
The latest version contains all changes.
10+
<!-- The latest version contains all changes. -->
11+
12+
### Added
13+
14+
- Debug symbol stripping for `cargo install` users (result: ~79% of the size of `4.0.1`)
15+
16+
### Changed
17+
18+
- Switched to `cargo` workspaces
1119

1220
### [4.0.1] - 2022-07-05
1321

Cargo.lock

Lines changed: 60 additions & 46 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 7 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -1,43 +1,12 @@
1-
[package]
2-
authors = ["Nick Gerace <[email protected]>"]
3-
categories = ["command-line-utilities", "command-line-interface"]
4-
description = "CLI tool to help keep track of your Git repositories."
5-
homepage = "https://nickgerace.dev"
6-
keywords = ["git", "cli"]
7-
license = "Apache-2.0"
8-
name = "gfold"
9-
readme = "README.md"
10-
repository = "https://github.com/nickgerace/gfold/"
1+
[workspace]
2+
members = ["crates/*"]
3+
default-members = ["crates/gfold"]
114

12-
edition = "2021"
13-
version = "4.0.1"
14-
15-
[dependencies]
16-
anyhow = { version = "1", features = ["backtrace"] }
17-
argh = "0"
18-
dirs = "4"
19-
git2 = { version = "0", default_features = false }
20-
log = "0"
21-
rayon = "1"
22-
serde = { version = "1", features = ["derive"] }
23-
serde_json = "1"
24-
termcolor = "1"
25-
thiserror = "1"
26-
toml = "0"
27-
28-
# Source: https://github.com/env-logger-rs/env_logger/blob/v0.9.0/Cargo.toml#L47
29-
# Removed features: ["regex", "termcolor"]
30-
env_logger = { version = "0", features = ["atty", "humantime"], default_features = false }
31-
32-
[profile.release]
5+
[profile.release.package.gfold]
336
codegen-units = 1
34-
35-
# Instruct linker to optimize at the link stage.
36-
lto = true
37-
38-
# There is a noticeable speed difference from level 3 to 'z' or 's'.
39-
# We need this speed for the user experience.
407
opt-level = 3
8+
strip = true
419

42-
# This application should not panic often and only read from the filesystem.
10+
[profile.release]
11+
lto = true
4312
panic = "abort"
File renamed without changes.

scripts/bench-loosely/src/main.rs renamed to crates/bench-loosely/src/main.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ fn main() {
2121
.parent()
2222
.expect("could not get parent");
2323

24-
println!("Running \"cargo build --release\"...");
24+
println!("running in {:?}: cargo build --release", &repo);
2525
let output = Command::new("cargo")
2626
.arg("build")
2727
.arg("--release")

crates/gfold/Cargo.toml

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
[package]
2+
authors = ["Nick Gerace <[email protected]>"]
3+
categories = ["command-line-utilities", "command-line-interface"]
4+
description = "CLI tool to help keep track of your Git repositories."
5+
homepage = "https://nickgerace.dev"
6+
keywords = ["git", "cli"]
7+
license = "Apache-2.0"
8+
name = "gfold"
9+
readme = "README.md"
10+
repository = "https://github.com/nickgerace/gfold/"
11+
12+
edition = "2021"
13+
version = "4.0.1"
14+
15+
[dependencies]
16+
anyhow = { version = "1", features = ["backtrace"] }
17+
argh = "0"
18+
dirs = "4"
19+
git2 = { version = "0", default_features = false }
20+
log = "0"
21+
rayon = "1"
22+
serde = { version = "1", features = ["derive"] }
23+
serde_json = "1"
24+
termcolor = "1"
25+
thiserror = "1"
26+
toml = "0"
27+
28+
# Source: https://github.com/env-logger-rs/env_logger/blob/v0.9.0/Cargo.toml#L47
29+
# Removed features: ["regex", "termcolor"]
30+
env_logger = { version = "0", features = ["atty", "humantime"], default_features = false }
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 commit comments

Comments
 (0)