Skip to content

Commit 97b3f7e

Browse files
committed
Merge branch 'consecutive-negotiation'
2 parents 4507f94 + 1571528 commit 97b3f7e

File tree

26 files changed

+1209
-36
lines changed

26 files changed

+1209
-36
lines changed

Cargo.lock

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

Cargo.toml

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ repository = "https://github.com/Byron/gitoxide"
55
authors = ["Sebastian Thiel <[email protected]>"]
66
edition = "2021"
77
license = "MIT OR Apache-2.0"
8-
version = "0.25.0"
8+
version = "0.26.0"
99
default-run = "gix"
1010
include = ["src/**/*", "LICENSE-*", "README.md", "CHANGELOG.md"]
1111
resolver = "2"
@@ -151,9 +151,9 @@ gitoxide-core-async-client = ["gitoxide-core/async-client", "futures-lite"]
151151
[dependencies]
152152
anyhow = "1.0.42"
153153

154-
gitoxide-core = { version = "^0.27.0", path = "gitoxide-core" }
154+
gitoxide-core = { version = "^0.28.0", path = "gitoxide-core" }
155155
gix-features = { version = "^0.29.0", path = "gix-features" }
156-
gix = { version = "^0.44.1", path = "gix", default-features = false }
156+
gix = { version = "^0.45.0", path = "gix", default-features = false }
157157
time = "0.3.19"
158158

159159
clap = { version = "4.1.1", features = ["derive", "cargo"] }
@@ -221,6 +221,7 @@ members = [
221221
"gix-packetline",
222222
"gix-mailmap",
223223
"gix-note",
224+
"gix-negotiate",
224225
"gix-fetchhead",
225226
"gix-prompt",
226227
"gix-filter",

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -88,6 +88,7 @@ is usable to some extent.
8888
* [gix-hashtable](https://github.com/Byron/gitoxide/blob/main/crate-status.md#gix-hashtable)
8989
* [gix-worktree](https://github.com/Byron/gitoxide/blob/main/crate-status.md#gix-worktree)
9090
* [gix-bitmap](https://github.com/Byron/gitoxide/blob/main/crate-status.md#gix-bitmap)
91+
* [gix-negotiate](https://github.com/Byron/gitoxide/blob/main/crate-status.md#gix-negotiate)
9192
* `gitoxide-core`
9293
* **very early** _(possibly without any documentation and many rough edges)_
9394
* [gix-date](https://github.com/Byron/gitoxide/blob/main/crate-status.md#gix-date)

cargo-smart-release/Cargo.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "cargo-smart-release"
3-
version = "0.19.0"
3+
version = "0.20.0"
44
authors = ["Sebastian Thiel <[email protected]>"]
55
repository = "https://github.com/Byron/gitoxide"
66
description = "Cargo subcommand for fearlessly releasing crates in workspaces."
@@ -25,7 +25,7 @@ cache-efficiency-debug = ["gix/cache-efficiency-debug"]
2525
vendored-openssl = ["crates-index/vendored-openssl"]
2626

2727
[dependencies]
28-
gix = { version = "^0.44.1", path = "../gix", default-features = false, features = ["max-performance-safe"] }
28+
gix = { version = "^0.45.0", path = "../gix", default-features = false, features = ["max-performance-safe"] }
2929
anyhow = "1.0.42"
3030
clap = { version = "4.1.0", features = ["derive", "cargo"] }
3131
env_logger = { version = "0.10.0", default-features = false, features = ["humantime", "auto-color"] }

crate-status.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -386,6 +386,12 @@ A mechanism to associate metadata with any object, and keep revisions of it usin
386386

387387
* [ ] CRUD for git notes
388388

389+
### gix-negotiate
390+
* **algorithms**
391+
- [ ] `noop`
392+
- [ ] `consecutive`
393+
- [ ] `skipping`
394+
389395
### gix-fetchhead
390396
* [ ] parse `FETCH_HEAD` information back entirely
391397
* [ ] write typical fetch-head lines

gitoxide-core/Cargo.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
name = "gitoxide-core"
33
description = "The library implementing all capabilities of the gitoxide CLI"
44
repository = "https://github.com/Byron/gitoxide"
5-
version = "0.27.0"
5+
version = "0.28.0"
66
authors = ["Sebastian Thiel <[email protected]>"]
77
license = "MIT/Apache-2.0"
88
edition = "2021"
@@ -38,7 +38,7 @@ serde = ["gix/serde", "serde_json", "dep:serde", "bytesize/serde"]
3838

3939
[dependencies]
4040
# deselect everything else (like "performance") as this should be controllable by the parent application.
41-
gix = { version = "^0.44.1", path = "../gix", default-features = false }
41+
gix = { version = "^0.45.0", path = "../gix", default-features = false }
4242
gix-pack-for-configuration-only = { package = "gix-pack", version = "^0.35.0", path = "../gix-pack", default-features = false, features = ["pack-cache-lru-dynamic", "pack-cache-lru-static"] }
4343
gix-transport-configuration-only = { package = "gix-transport", version = "^0.31.0", path = "../gix-transport", default-features = false }
4444
serde = { version = "1.0.114", optional = true, default-features = false, features = ["derive"] }

gix-commitgraph/CHANGELOG.md

Lines changed: 37 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,40 @@ All notable changes to this project will be documented in this file.
55
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
66
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
77

8+
## 0.15.0 (2023-05-19)
9+
10+
### New Features (BREAKING)
11+
12+
- <csr-id-ed258da9015d2d68734aeac485dd009760fc4da4/> `describe` usees commitgraph.
13+
With it it can leverage the commitgraph data structure would would be more prominent
14+
on server-side applications, presumably.
15+
16+
### Refactor (BREAKING)
17+
18+
- <csr-id-967f3b954e9fb4fc7757f8920998173caf0491ab/> make API more consistent with other `gix-*` crates.
19+
For that, we remove duplicate import paths for types.
20+
We also improve lifetimes around parent iteration, and make the type explicit.
21+
22+
### Commit Statistics
23+
24+
<csr-read-only-do-not-edit/>
25+
26+
- 2 commits contributed to the release over the course of 1 calendar day.
27+
- 21 days passed between releases.
28+
- 2 commits were understood as [conventional](https://www.conventionalcommits.org).
29+
- 0 issues like '(#ID)' were seen in commit messages
30+
31+
### Commit Details
32+
33+
<csr-read-only-do-not-edit/>
34+
35+
<details><summary>view details</summary>
36+
37+
* **Uncategorized**
38+
- `describe` usees commitgraph. ([`ed258da`](https://github.com/Byron/gitoxide/commit/ed258da9015d2d68734aeac485dd009760fc4da4))
39+
- Make API more consistent with other `gix-*` crates. ([`967f3b9`](https://github.com/Byron/gitoxide/commit/967f3b954e9fb4fc7757f8920998173caf0491ab))
40+
</details>
41+
842
## 0.14.0 (2023-04-27)
943

1044
### New Features (BREAKING)
@@ -21,8 +55,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
2155

2256
<csr-read-only-do-not-edit/>
2357

24-
- 9 commits contributed to the release over the course of 56 calendar days.
25-
- 60 days passed between releases.
58+
- 10 commits contributed to the release over the course of 57 calendar days.
59+
- 61 days passed between releases.
2660
- 1 commit was understood as [conventional](https://www.conventionalcommits.org).
2761
- 1 unique issue was worked on: [#814](https://github.com/Byron/gitoxide/issues/814)
2862

@@ -35,6 +69,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
3569
* **[#814](https://github.com/Byron/gitoxide/issues/814)**
3670
- Rename `serde1` cargo feature to `serde` and use the weak-deps cargo capability. ([`b83ee36`](https://github.com/Byron/gitoxide/commit/b83ee366a3c65c717beb587ad809268f1c54b8ad))
3771
* **Uncategorized**
72+
- Release gix-commitgraph v0.14.0, gitoxide-core v0.26.0, gitoxide v0.24.0 ([`9f2317f`](https://github.com/Byron/gitoxide/commit/9f2317f2514872001168d2be6e33e2ee2872420e))
3873
- Release gix-hash v0.11.1, gix-path v0.7.4, gix-glob v0.6.0, gix-attributes v0.11.0, gix-config-value v0.11.0, gix-fs v0.1.1, gix-tempfile v5.0.3, gix-utils v0.1.1, gix-lock v5.0.1, gix-object v0.29.1, gix-ref v0.28.0, gix-sec v0.7.0, gix-config v0.21.0, gix-prompt v0.4.0, gix-url v0.17.0, gix-credentials v0.13.0, gix-diff v0.29.0, gix-discover v0.17.0, gix-hashtable v0.2.0, gix-ignore v0.1.0, gix-bitmap v0.2.3, gix-traverse v0.25.0, gix-index v0.16.0, gix-mailmap v0.12.0, gix-pack v0.34.0, gix-odb v0.44.0, gix-packetline v0.16.0, gix-transport v0.30.0, gix-protocol v0.31.0, gix-revision v0.13.0, gix-refspec v0.10.0, gix-worktree v0.16.0, gix v0.44.0, safety bump 7 crates ([`91134a1`](https://github.com/Byron/gitoxide/commit/91134a11c8ba0e942f692488ec9bce9fa1086324))
3974
- Release gix-utils v0.1.0, gix-hash v0.11.0, gix-date v0.5.0, gix-features v0.29.0, gix-actor v0.20.0, gix-object v0.29.0, gix-archive v0.1.0, gix-fs v0.1.0, safety bump 25 crates ([`8dbd0a6`](https://github.com/Byron/gitoxide/commit/8dbd0a60557a85acfa231800a058cbac0271a8cf))
4075
- Merge branch 'main' into dev ([`cdef398`](https://github.com/Byron/gitoxide/commit/cdef398c4a3bd01baf0be2c27a3f77a400172b0d))

gix-commitgraph/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "gix-commitgraph"
3-
version = "0.14.0"
3+
version = "0.15.0"
44
repository = "https://github.com/Byron/gitoxide"
55
documentation = "https://git-scm.com/docs/commit-graph#:~:text=The%20commit-graph%20file%20is%20a%20supplemental%20data%20structure,or%20in%20the%20info%20directory%20of%20an%20alternate."
66
license = "MIT/Apache-2.0"

gix-commitgraph/src/lib.rs

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,8 @@
1515
#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))]
1616
#![deny(missing_docs, rust_2018_idioms, unsafe_code)]
1717

18+
use std::path::Path;
19+
1820
/// A single commit-graph file.
1921
///
2022
/// All operations on a `File` are local to that graph file. Since a commit graph can span multiple
@@ -41,6 +43,11 @@ pub struct Graph {
4143
files: Vec<File>,
4244
}
4345

46+
/// Instantiate a commit graph from an `.git/objects/info` directory, or one of the various commit-graph files.
47+
pub fn at(path: impl AsRef<Path>) -> Result<Graph, init::Error> {
48+
Graph::at(path)
49+
}
50+
4451
mod access;
4552
pub mod file;
4653
///

gix-commitgraph/tests/access/mod.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ fn octupus_merges() -> crate::Result {
3030
"four_parents",
3131
],
3232
);
33-
let cg = Graph::from_info_dir(repo_dir.join(".git").join("objects").join("info"))?;
33+
let cg = Graph::at(repo_dir.join(".git").join("objects").join("info"))?;
3434
check_common(&cg, &refs);
3535

3636
assert_eq!(cg.commit_at(refs["root"].pos()).generation(), 1);
@@ -48,7 +48,7 @@ fn octupus_merges() -> crate::Result {
4848
fn single_commit() -> crate::Result {
4949
let repo_dir = make_readonly_repo("single_commit.sh");
5050
let refs = inspect_refs(&repo_dir, &["commit"]);
51-
let cg = Graph::from_info_dir(repo_dir.join(".git").join("objects").join("info"))?;
51+
let cg = gix_commitgraph::at(repo_dir.join(".git").join("objects").join("info"))?;
5252
check_common(&cg, &refs);
5353

5454
assert_eq!(cg.commit_at(refs["commit"].pos()).generation(), 1);

gix-negotiate/CHANGELOG.md

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
# Changelog
2+
3+
All notable changes to this project will be documented in this file.
4+
5+
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
6+
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
7+
8+
## v0.1.0 (2023-05-19)
9+
10+
Initial release with a single function to calculate the window size for `HAVE` lines.
11+
12+
### Commit Statistics
13+
14+
<csr-read-only-do-not-edit/>
15+
16+
- 1 commit contributed to the release.
17+
- 0 commits were understood as [conventional](https://www.conventionalcommits.org).
18+
- 0 issues like '(#ID)' were seen in commit messages
19+
20+
### Commit Details
21+
22+
<csr-read-only-do-not-edit/>
23+
24+
<details><summary>view details</summary>
25+
26+
* **Uncategorized**
27+
- Add new crate for implementing and testing git negotiation logic. ([`372ba09`](https://github.com/Byron/gitoxide/commit/372ba09bb00e3fab674f0251f697aab11c5559f8))
28+
</details>
29+

gix-negotiate/Cargo.toml

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
[package]
2+
name = "gix-negotiate"
3+
version = "0.1.0"
4+
repository = "https://github.com/Byron/gitoxide"
5+
license = "MIT/Apache-2.0"
6+
description = "A crate of the gitoxide project implementing negotiation algorithms"
7+
authors = ["Sebastian Thiel <[email protected]>"]
8+
edition = "2021"
9+
rust-version = "1.64"
10+
11+
[lib]
12+
doctest = false
13+
test = false
14+
15+
[dependencies]
16+
gix-hash = { version = "^0.11.1", path = "../gix-hash" }
17+
gix-object = { version = "^0.29.2", path = "../gix-object" }
18+
gix-commitgraph = { version = "^0.15.0", path = "../gix-commitgraph" }
19+
gix-revision = { version = "^0.14.0", path = "../gix-revision" }
20+
thiserror = "1.0.40"
21+
smallvec = "1.10.0"
22+
bitflags = "2"
23+
24+
[dev-dependencies]
25+
gix-testtools = { path = "../tests/tools" }
26+
gix-odb = { path = "../gix-odb" }
27+
gix-ref = { path = "../gix-ref" }

0 commit comments

Comments
 (0)