Skip to content

Commit 92e082a

Browse files
committed
A very first version of gix progress show (#450)
1 parent 8d17dc6 commit 92e082a

File tree

9 files changed

+756
-679
lines changed

9 files changed

+756
-679
lines changed

Cargo.lock

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

Cargo.toml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,9 @@ env_logger = { version = "0.9.0", default-features = false }
9292
crosstermion = { version = "0.10.1", optional = true, default-features = false }
9393
futures-lite = { version = "1.12.0", optional = true, default-features = false, features = ["std"] }
9494

95+
# for show-progress
96+
owo-colors = "3.5.0"
97+
9598
document-features = { version = "0.2.0", optional = true }
9699

97100
[profile.dev.package]

README.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,10 @@ Please see _'Development Status'_ for a listing of all crates and their capabili
2727
* Based on the [git-hours] algorithm.
2828
* See the [discussion][git-hours-discussion] for some performance data.
2929
* **the `gix` program** _(plumbing)_ - lower level commands for use in automation
30+
* **progress**
31+
* [x] **show** - provide an overview of what works and what doesn't from the perspective of the git configuration.
32+
This is likely to change a lot over time depending on actual needs, but maybe useful for you to see
33+
if particular git-configuration is picked up and where it deviates.
3034
* **config** - list the complete git configuration in human-readable form and optionally filter sections by name.
3135
* **exclude**
3236
* [x] **query** - check if path specs are excluded via gits exclusion rules like `.gitignore`.

src/plumbing/main.rs

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,12 @@ use gitoxide_core as core;
1414
use gitoxide_core::pack::verify;
1515

1616
use crate::{
17-
plumbing::options::{
18-
commit, config, credential, exclude, free, mailmap, odb, remote, revision, tree, Args, Subcommands,
17+
plumbing::{
18+
options::{
19+
commit, config, credential, exclude, free, mailmap, odb, progress, remote, revision, tree, Args,
20+
Subcommands,
21+
},
22+
show_progress,
1923
},
2024
shared::pretty::prepare_and_run,
2125
};
@@ -111,6 +115,7 @@ pub fn main() -> Result<()> {
111115
})?;
112116

113117
match cmd {
118+
Subcommands::Progress(progress::Subcommands::Show) => show_progress(),
114119
Subcommands::Credential(cmd) => core::repository::credential(
115120
repository(Mode::StrictWithGitInstallConfig)?,
116121
match cmd {

src/plumbing/mod.rs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,8 @@
11
mod main;
22
pub use main::main;
33

4+
#[path = "progress.rs"]
5+
mod progress_impl;
6+
pub use progress_impl::show_progress;
7+
48
mod options;

0 commit comments

Comments
 (0)