Skip to content

Commit

Permalink
Use [patch.crates-io] section instead of path key
Browse files Browse the repository at this point in the history
  • Loading branch information
JohnTitor committed Jun 6, 2021
1 parent 7ebc9e7 commit f47515b
Show file tree
Hide file tree
Showing 6 changed files with 24 additions and 16 deletions.
15 changes: 14 additions & 1 deletion Cargo.toml
@@ -1,2 +1,15 @@
[workspace]
members = ["phf", "phf_codegen", "phf_codegen/test", "phf_generator", "phf_macros", "phf_shared"]
members = [
"phf",
"phf_codegen",
"phf_codegen/test",
"phf_generator",
"phf_macros",
"phf_shared"
]

[patch.crates-io]
phf = { path = "phf" }
phf_generator = { path = "./phf_generator" }
phf_macros = { path = "./phf_macros" }
phf_shared = { path = "./phf_shared" }
4 changes: 2 additions & 2 deletions phf/Cargo.toml
Expand Up @@ -22,10 +22,10 @@ macros = [
]

[dependencies]
phf_shared = { version = "0.8.0", default-features = false, path = "../phf_shared" }
phf_shared = { version = "0.8.0", default-features = false }

proc-macro-hack = { version = "0.5.4", optional = true }
phf_macros = { version = "0.8.0", optional = true, path = "../phf_macros" }
phf_macros = { version = "0.8.0", optional = true }

[package.metadata.docs.rs]
features = ["macros", ]
Expand Down
4 changes: 2 additions & 2 deletions phf_codegen/Cargo.toml
Expand Up @@ -8,5 +8,5 @@ repository = "https://github.com/sfackler/rust-phf"
edition = "2018"

[dependencies]
phf_generator = { version = "0.8.0", path = "../phf_generator" }
phf_shared = { version = "0.8.0", path = "../phf_shared" }
phf_generator = "0.8.0"
phf_shared = "0.8.0"
9 changes: 2 additions & 7 deletions phf_codegen/test/Cargo.toml
Expand Up @@ -6,14 +6,9 @@ build = "build.rs"
edition = "2018"

[dependencies]
phf = { version = "0.8", features = ["unicase"] }
unicase = "2.4.0"

[build-dependencies]
phf_codegen = "0.8"
unicase = "2.4.0"

[build-dependencies.phf_codegen]
path = ".."

[dependencies.phf]
path = "../../phf"
features = ["unicase"]
2 changes: 1 addition & 1 deletion phf_generator/Cargo.toml
Expand Up @@ -9,7 +9,7 @@ edition = "2018"

[dependencies]
rand = { version = "0.8", features = ["small_rng"] }
phf_shared = { version = "0.8.0", path = "../phf_shared", default-features = false }
phf_shared = { version = "0.8.0", default-features = false }
# for stable black_box()
criterion = { version = "0.3", optional = true }

Expand Down
6 changes: 3 additions & 3 deletions phf_macros/Cargo.toml
Expand Up @@ -16,10 +16,10 @@ quote = "1"
proc-macro2 = "1"
proc-macro-hack = "0.5.4"

phf_generator = { version = "0.8.0", path = "../phf_generator" }
phf_shared = { version = "0.8.0", path = "../phf_shared", default-features = false }
phf_generator = "0.8.0"
phf_shared = { version = "0.8.0", default-features = false }

[dev-dependencies]
trybuild = "1.0"
phf = { version = "0.8", path = "../phf", features = ["macros", "unicase"] }
phf = { version = "0.8", features = ["macros", "unicase"] }
unicase = "2.4.0"

0 comments on commit f47515b

Please sign in to comment.