fedimint / fedimint

Federated E-Cash Mint
https://fedimint.org/
MIT License
536 stars 209 forks source link

Convert most `[package]` fields to `{workspace = true }` #5190

Closed dpc closed 8 hours ago

dpc commented 2 weeks ago

This works:

> g diff HEAD
diff --git a/fedimint-bitcoind/Cargo.toml b/fedimint-bitcoind/Cargo.toml
index 573cd58d4b..a12a098bfb 100644
--- a/fedimint-bitcoind/Cargo.toml
+++ b/fedimint-bitcoind/Cargo.toml
@@ -1,6 +1,6 @@
 [package]
 name = "fedimint-bitcoind"
-version = "0.4.0-alpha"
+version = { workspace = true }
 authors = ["The Fedimint Developers"]
 edition = "2021"
 description = "Bitcoin Core connectivity used by Fedimint"

We should use { workspace = true } for anything that can be done this way, mostly because it expresses the shared nature of these fields well.

Minimega12121 commented 2 weeks ago

So do we have to change to { workspace = true } on each cargo or only specific ones ?

This works:

> g diff HEAD
diff --git a/fedimint-bitcoind/Cargo.toml b/fedimint-bitcoind/Cargo.toml
index 573cd58d4b..a12a098bfb 100644
--- a/fedimint-bitcoind/Cargo.toml
+++ b/fedimint-bitcoind/Cargo.toml
@@ -1,6 +1,6 @@
 [package]
 name = "fedimint-bitcoind"
-version = "0.4.0-alpha"
+version = { workspace = true }
 authors = ["The Fedimint Developers"]
 edition = "2021"
 description = "Bitcoin Core connectivity used by Fedimint"

We should use { workspace = true } for anything that can be done this way, mostly because it expresses the shared nature of these fields well.

So do we have to change version to { workspace = true } on each cargo or only specific ones ?

dpc commented 2 weeks ago

Everywhere where it makes sense (most if not all Cargo.tomls). `version, authors, edition, etc.