-
-
Notifications
You must be signed in to change notification settings - Fork 477
Expand file tree
/
Copy pathCargo.toml
More file actions
117 lines (100 loc) · 4.01 KB
/
Cargo.toml
File metadata and controls
117 lines (100 loc) · 4.01 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
lints.workspace = true
[package]
name = "gix-protocol"
version = "0.61.0"
repository = "https://github.com/GitoxideLabs/gitoxide"
license = "MIT OR Apache-2.0"
description = "A crate of the gitoxide project for implementing git protocols"
authors = ["Sebastian Thiel <[email protected]>"]
edition = "2024"
include = ["/src/**/*", "/LICENSE-*", "!/tests/**/*"]
rust-version = "1.85"
[lib]
doctest = false
[features]
#! ### _Mutually exclusive client _
#! The _client_ portion of the protocol uses `gix-transport` to communicate to a server. For it to be available, one of the following features must
#! be selected.
#!
#! Specifying both causes a compile error, preventing the use of `--all-features`.
## If set, blocking command implementations are available and will use the blocking version of the `gix-transport` crate.
blocking-client = [
"gix-transport/blocking-client",
"maybe-async/is_sync",
"handshake",
"fetch"
]
## As above, but provides async implementations instead.
# no `dep:` for futures-lite (https://github.com/rust-secure-code/cargo-auditable/issues/124)
async-client = [
"gix-transport/async-client",
"dep:async-trait",
"dep:futures-io",
"futures-lite",
"handshake",
"fetch"
]
## Add implementations for performing a `handshake` along with the dependencies needed for it.
handshake = ["dep:gix-credentials"]
## Add implementations for performing a `fetch` (for packs) along with the dependencies needed for it.
fetch = [
"dep:gix-negotiate",
"dep:gix-object",
"dep:gix-revwalk",
"dep:gix-lock",
"dep:gix-refspec",
"dep:gix-trace",
]
#! ### Other
## Enable support for the SHA-1 hash by enabling the respective feature in the `gix-hash` crate.
sha1 = ["gix-hash/sha1"]
## Enable support for the SHA-256 hash by enabling the respective feature in the `gix-hash` crate.
sha256 = ["gix-hash/sha256"]
## Data structures implement `serde::Serialize` and `serde::Deserialize`.
serde = ["dep:serde", "bstr/serde", "gix-transport/serde", "gix-hash/serde", "gix-shallow/serde"]
[[test]]
name = "blocking"
path = "tests/blocking-protocol.rs"
required-features = ["blocking-client"]
[[test]]
name = "async"
path = "tests/async-protocol.rs"
required-features = ["async-client"]
[dependencies]
gix-features = { version = "^0.48.0", path = "../gix-features", features = [
"progress",
] }
gix-transport = { version = "^0.57.0", path = "../gix-transport" }
gix-hash = { version = "^0.25.0", path = "../gix-hash" }
gix-shallow = { version = "^0.12.0", path = "../gix-shallow" }
gix-date = { version = "^0.15.3", path = "../gix-date" }
gix-utils = { version = "^0.3.2", path = "../gix-utils" }
gix-ref = { version = "^0.63.0", path = "../gix-ref" }
gix-trace = { version = "^0.1.19", path = "../gix-trace", optional = true }
gix-negotiate = { version = "^0.31.0", path = "../gix-negotiate", optional = true }
gix-object = { version = "^0.60.0", path = "../gix-object", optional = true }
gix-revwalk = { version = "^0.31.0", path = "../gix-revwalk", optional = true }
gix-credentials = { version = "^0.38.0", path = "../gix-credentials", optional = true }
gix-refspec = { version = "^0.41.0", path = "../gix-refspec", optional = true }
gix-lock = { version = "^23.0.0", path = "../gix-lock", optional = true }
thiserror = "2.0.18"
nonempty = "0.12.0"
serde = { version = "1.0.114", optional = true, default-features = false, features = [
"derive",
] }
bstr = { version = "1.12.0", default-features = false, features = [
"std",
"unicode",
] }
# for async-client
async-trait = { version = "0.1.51", optional = true }
futures-io = { version = "0.3.32", optional = true }
futures-lite = { version = "2.1.0", optional = true }
maybe-async = "0.2.6"
document-features = { version = "0.2.0", optional = true }
[dev-dependencies]
async-std = { version = "1.9.0", features = ["attributes"] }
gix-packetline = { path = "../gix-packetline", version = "^0.21.3" }
gix-hash = { path = "../gix-hash", features = ["sha1"] }
[package.metadata.docs.rs]
features = ["sha1", "blocking-client", "document-features", "serde"]