Skip to content

Commit 63216ae

Browse files
workspace: Defines cuprate members as workspace dependencies (#326)
Defines cuprate members as workspace dependencies - Defines cuprate members as workspace dependencies - Changed all `path` import into `workspace = true` Co-authored-by: Boog900 <boog900@tutanota.com>
1 parent b8e2d00 commit 63216ae

File tree

21 files changed

+143
-114
lines changed

21 files changed

+143
-114
lines changed

Cargo.toml

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,35 @@ opt-level = 1
5050
opt-level = 3
5151

5252
[workspace.dependencies]
53+
# Cuprate members
54+
cuprate-fast-sync = { path = "consensus/fast-sync" ,default-features = false}
55+
cuprate-consensus-rules = { path = "consensus/rules" ,default-features = false}
56+
cuprate-constants = { path = "constants" ,default-features = false}
57+
cuprate-consensus = { path = "consensus" ,default-features = false}
58+
cuprate-consensus-context = { path = "consensus/context" ,default-features = false}
59+
cuprate-cryptonight = { path = "cryptonight" ,default-features = false}
60+
cuprate-helper = { path = "helper" ,default-features = false}
61+
cuprate-epee-encoding = { path = "net/epee-encoding" ,default-features = false}
62+
cuprate-fixed-bytes = { path = "net/fixed-bytes" ,default-features = false}
63+
cuprate-levin = { path = "net/levin" ,default-features = false}
64+
cuprate-wire = { path = "net/wire" ,default-features = false}
65+
cuprate-p2p = { path = "p2p/p2p" ,default-features = false}
66+
cuprate-p2p-core = { path = "p2p/p2p-core" ,default-features = false}
67+
cuprate-dandelion-tower = { path = "p2p/dandelion-tower" ,default-features = false}
68+
cuprate-async-buffer = { path = "p2p/async-buffer" ,default-features = false}
69+
cuprate-address-book = { path = "p2p/address-book" ,default-features = false}
70+
cuprate-blockchain = { path = "storage/blockchain" ,default-features = false}
71+
cuprate-database = { path = "storage/database" ,default-features = false}
72+
cuprate-database-service = { path = "storage/service" ,default-features = false}
73+
cuprate-txpool = { path = "storage/txpool" ,default-features = false}
74+
cuprate-pruning = { path = "pruning" ,default-features = false}
75+
cuprate-test-utils = { path = "test-utils" ,default-features = false}
76+
cuprate-types = { path = "types" ,default-features = false}
77+
cuprate-json-rpc = { path = "rpc/json-rpc" ,default-features = false}
78+
cuprate-rpc-types = { path = "rpc/types" ,default-features = false}
79+
cuprate-rpc-interface = { path = "rpc/interface" ,default-features = false}
80+
81+
# External dependencies
5382
anyhow = { version = "1.0.89", default-features = false }
5483
async-trait = { version = "0.1.82", default-features = false }
5584
bitflags = { version = "2.6.0", default-features = false }

binaries/cuprated/Cargo.toml

Lines changed: 25 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -9,31 +9,31 @@ repository = "https://github.com/Cuprate/cuprate/tree/main/binaries/cuprated"
99

1010
[dependencies]
1111
# TODO: after v1.0.0, remove unneeded dependencies.
12-
cuprate-consensus = { path = "../../consensus" }
13-
cuprate-fast-sync = { path = "../../consensus/fast-sync" }
14-
cuprate-consensus-context = { path = "../../consensus/context" }
15-
cuprate-consensus-rules = { path = "../../consensus/rules" }
16-
cuprate-cryptonight = { path = "../../cryptonight" }
17-
cuprate-helper = { path = "../../helper" }
18-
cuprate-epee-encoding = { path = "../../net/epee-encoding" }
19-
cuprate-fixed-bytes = { path = "../../net/fixed-bytes" }
20-
cuprate-levin = { path = "../../net/levin" }
21-
cuprate-wire = { path = "../../net/wire" }
22-
cuprate-p2p = { path = "../../p2p/p2p" }
23-
cuprate-p2p-core = { path = "../../p2p/p2p-core" }
24-
cuprate-dandelion-tower = { path = "../../p2p/dandelion-tower" }
25-
cuprate-async-buffer = { path = "../../p2p/async-buffer" }
26-
cuprate-address-book = { path = "../../p2p/address-book" }
27-
cuprate-blockchain = { path = "../../storage/blockchain", features = ["service"] }
28-
cuprate-database-service = { path = "../../storage/service" }
29-
cuprate-txpool = { path = "../../storage/txpool" }
30-
cuprate-database = { path = "../../storage/database" }
31-
cuprate-pruning = { path = "../../pruning" }
32-
cuprate-test-utils = { path = "../../test-utils" }
33-
cuprate-types = { path = "../../types" }
34-
cuprate-json-rpc = { path = "../../rpc/json-rpc" }
35-
cuprate-rpc-interface = { path = "../../rpc/interface" }
36-
cuprate-rpc-types = { path = "../../rpc/types" }
12+
cuprate-consensus = { workspace = true }
13+
cuprate-fast-sync = { workspace = true }
14+
cuprate-consensus-context = { workspace = true }
15+
cuprate-consensus-rules = { workspace = true }
16+
cuprate-cryptonight = { workspace = true }
17+
cuprate-helper = { workspace = true }
18+
cuprate-epee-encoding = { workspace = true }
19+
cuprate-fixed-bytes = { workspace = true }
20+
cuprate-levin = { workspace = true }
21+
cuprate-wire = { workspace = true }
22+
cuprate-p2p = { workspace = true }
23+
cuprate-p2p-core = { workspace = true }
24+
cuprate-dandelion-tower = { workspace = true }
25+
cuprate-async-buffer = { workspace = true }
26+
cuprate-address-book = { workspace = true }
27+
cuprate-blockchain = { workspace = true, features = ["service"] }
28+
cuprate-database-service = { workspace = true }
29+
cuprate-txpool = { workspace = true }
30+
cuprate-database = { workspace = true }
31+
cuprate-pruning = { workspace = true }
32+
cuprate-test-utils = { workspace = true }
33+
cuprate-types = { workspace = true }
34+
cuprate-json-rpc = { workspace = true }
35+
cuprate-rpc-interface = { workspace = true }
36+
cuprate-rpc-types = { workspace = true }
3737

3838
# TODO: after v1.0.0, remove unneeded dependencies.
3939
anyhow = { workspace = true }

consensus/Cargo.toml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,10 @@ authors = ["Boog900"]
88
repository = "https://github.com/Cuprate/cuprate/tree/main/consensus"
99

1010
[dependencies]
11-
cuprate-helper = { path = "../helper", default-features = false, features = ["std", "asynch", "num"] }
12-
cuprate-consensus-rules = { path = "./rules", features = ["rayon"] }
13-
cuprate-types = { path = "../types" }
14-
cuprate-consensus-context = { path = "./context" }
11+
cuprate-helper = { workspace = true, default-features = false, features = ["std", "asynch", "num"] }
12+
cuprate-consensus-rules = { workspace = true, features = ["rayon"] }
13+
cuprate-types = { workspace = true }
14+
cuprate-consensus-context = { workspace = true }
1515

1616
cfg-if = { workspace = true }
1717
thiserror = { workspace = true }
@@ -28,8 +28,8 @@ hex = { workspace = true }
2828
rand = { workspace = true }
2929

3030
[dev-dependencies]
31-
cuprate-test-utils = { path = "../test-utils" }
32-
cuprate-consensus-rules = {path = "./rules", features = ["proptest"]}
31+
cuprate-test-utils = { workspace = true }
32+
cuprate-consensus-rules = { workspace = true, features = ["proptest"]}
3333

3434
hex-literal = { workspace = true }
3535
curve25519-dalek = { workspace = true }

consensus/context/Cargo.toml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,9 @@ license = "MIT"
66
authors = ["SyntheticBird","Boog900"]
77

88
[dependencies]
9-
cuprate-consensus-rules = { path = "../rules", features = ["proptest"]}
10-
cuprate-helper = { path = "../../helper", default-features = false, features = ["std", "cast", "num", "asynch"] }
11-
cuprate-types = { path = "../../types", default-features = false, features = ["blockchain"] }
9+
cuprate-consensus-rules = { workspace = true, features = ["proptest"]}
10+
cuprate-helper = { workspace = true, default-features = false, features = ["std", "cast", "num", "asynch"] }
11+
cuprate-types = { workspace = true, default-features = false, features = ["blockchain"] }
1212

1313
futures = { workspace = true, features = ["std", "async-await"] }
1414
tokio = { workspace = true, features = ["rt-multi-thread", "macros"]}
@@ -24,4 +24,4 @@ thread_local = { workspace = true }
2424
hex = { workspace = true }
2525

2626
[lints]
27-
workspace = true
27+
workspace = true

consensus/fast-sync/Cargo.toml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -9,12 +9,12 @@ name = "cuprate-fast-sync-create-hashes"
99
path = "src/create.rs"
1010

1111
[dependencies]
12-
cuprate-blockchain = { path = "../../storage/blockchain" }
13-
cuprate-consensus = { path = ".." }
14-
cuprate-consensus-rules = { path = "../rules" }
15-
cuprate-consensus-context = { path = "../context" }
16-
cuprate-types = { path = "../../types" }
17-
cuprate-helper = { path = "../../helper", features = ["cast"] }
12+
cuprate-blockchain = { workspace = true }
13+
cuprate-consensus = { workspace = true }
14+
cuprate-consensus-rules = { workspace = true }
15+
cuprate-consensus-context = { workspace = true }
16+
cuprate-types = { workspace = true }
17+
cuprate-helper = { workspace = true, features = ["cast"] }
1818

1919
clap = { workspace = true, features = ["derive", "std"] }
2020
hex = { workspace = true }

consensus/rules/Cargo.toml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,10 @@ proptest = ["cuprate-types/proptest"]
1111
rayon = ["dep:rayon"]
1212

1313
[dependencies]
14-
cuprate-constants = { path = "../../constants", default-features = false, features = ["block"] }
15-
cuprate-helper = { path = "../../helper", default-features = false, features = ["std", "cast"] }
16-
cuprate-types = { path = "../../types", default-features = false }
17-
cuprate-cryptonight = {path = "../../cryptonight"}
14+
cuprate-constants = { workspace = true, default-features = false, features = ["block"] }
15+
cuprate-helper = { workspace = true, default-features = false, features = ["std", "cast"] }
16+
cuprate-types = { workspace = true, default-features = false }
17+
cuprate-cryptonight = { workspace = true }
1818

1919
monero-serai = { workspace = true, features = ["std"] }
2020
curve25519-dalek = { workspace = true, features = ["alloc", "zeroize", "precomputed-tables"] }

helper/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ thread = ["std", "dep:target_os_lib"]
2525
tx = ["dep:monero-serai"]
2626

2727
[dependencies]
28-
cuprate-constants = { path = "../constants", optional = true, features = ["block"] }
28+
cuprate-constants = { workspace = true, optional = true, features = ["block"] }
2929

3030
chrono = { workspace = true, optional = true, features = ["std", "clock"] }
3131
crossbeam = { workspace = true, optional = true }

net/epee-encoding/Cargo.toml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,8 @@ default = ["std"]
1515
std = ["dep:thiserror", "bytes/std", "cuprate-fixed-bytes/std"]
1616

1717
[dependencies]
18-
cuprate-helper = { path = "../../helper", default-features = false, features = ["cast"] }
19-
cuprate-fixed-bytes = { path = "../fixed-bytes", default-features = false }
18+
cuprate-helper = { workspace = true, default-features = false, features = ["cast"] }
19+
cuprate-fixed-bytes = { workspace = true, default-features = false }
2020

2121
paste = "1.0.15"
2222
ref-cast = "1.0.23"
@@ -27,4 +27,4 @@ thiserror = { workspace = true, optional = true}
2727
hex = { workspace = true, features = ["default"] }
2828

2929
[lints]
30-
workspace = true
30+
workspace = true

net/levin/Cargo.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ default = []
1212
tracing = ["dep:tracing", "tokio-util/tracing"]
1313

1414
[dependencies]
15-
cuprate-helper = { path = "../../helper", default-features = false, features = ["cast"] }
15+
cuprate-helper = { workspace = true, default-features = false, features = ["cast"] }
1616

1717
cfg-if = { workspace = true }
1818
thiserror = { workspace = true }
@@ -30,4 +30,4 @@ tokio = { workspace = true, features = ["full"] }
3030
futures = { workspace = true, features = ["std"] }
3131

3232
[lints]
33-
workspace = true
33+
workspace = true

net/wire/Cargo.toml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,11 +11,11 @@ default = []
1111
tracing = ["cuprate-levin/tracing"]
1212

1313
[dependencies]
14-
cuprate-levin = { path = "../levin" }
15-
cuprate-epee-encoding = { path = "../epee-encoding" }
16-
cuprate-fixed-bytes = { path = "../fixed-bytes" }
17-
cuprate-types = { path = "../../types", default-features = false, features = ["epee"] }
18-
cuprate-helper = { path = "../../helper", default-features = false, features = ["map"] }
14+
cuprate-levin = { workspace = true }
15+
cuprate-epee-encoding = { workspace = true }
16+
cuprate-fixed-bytes = { workspace = true }
17+
cuprate-types = { workspace = true, default-features = false, features = ["epee"] }
18+
cuprate-helper = { workspace = true, default-features = false, features = ["map"] }
1919

2020
bitflags = { workspace = true, features = ["std"] }
2121
bytes = { workspace = true, features = ["std"] }

0 commit comments

Comments
 (0)