Skip to content

Commit

Permalink
Use workspace inheritance for common package properties.
Browse files Browse the repository at this point in the history
This will simplify maintenance of rust-version and edition.
In principle, individual packages might differ, but we should avoid
doing that without good reason, because that would mean moving code from
one package to another could break the code or violate MSRV.
  • Loading branch information
kpreid committed Jun 10, 2024
1 parent 09c2ae8 commit f8ad2f8
Show file tree
Hide file tree
Showing 13 changed files with 51 additions and 43 deletions.
10 changes: 10 additions & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,16 @@ members = [
# in a workspace, but would be implicit in a single package with edition="2021".)
resolver = "2"

[workspace.package]
# When changing any of these values, be sure to also update the non-workspace packages
# as listed above, if applicable.
edition = "2021"
rust-version = "1.77"
license = "MIT OR Apache-2.0"
authors = ["Kevin Reid <[email protected]>"]
# TODO: add homepage = "..." when we have one
repository = "https://github.com/kpreid/all-is-cubes"

[workspace.dependencies]
all-is-cubes = { path = "all-is-cubes", version = "0.7.1", default-features = false }
all-is-cubes-base = { path = "all-is-cubes-base", version = "0.7.1", default-features = false }
Expand Down
8 changes: 4 additions & 4 deletions all-is-cubes-base/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
[package]
name = "all-is-cubes-base"
version = "0.7.1"
authors = ["Kevin Reid <[email protected]>"]
edition = "2021"
rust-version = "1.73"
authors.workspace = true
edition.workspace = true
rust-version.workspace = true
description = "Helper library for all-is-cubes. Do not use directly."
repository = "https://github.com/kpreid/all-is-cubes"
repository.workspace = true
license = "MIT OR Apache-2.0"

[lib]
Expand Down
8 changes: 4 additions & 4 deletions all-is-cubes-content/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
[package]
name = "all-is-cubes-content"
version = "0.7.0"
authors = ["Kevin Reid <[email protected]>"]
edition = "2021"
rust-version = "1.73"
authors.workspace = true
edition.workspace = true
rust-version.workspace = true
description = "Demo/default game content for the all-is-cubes engine."
# TODO: add homepage = "..." when we have one
repository = "https://github.com/kpreid/all-is-cubes"
repository.workspace = true
license = "MIT OR Apache-2.0"
categories = ["games"]

Expand Down
8 changes: 4 additions & 4 deletions all-is-cubes-desktop/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
[package]
name = "all-is-cubes-desktop"
version = "0.7.0"
authors = ["Kevin Reid <[email protected]>"]
edition = "2021"
rust-version = "1.77"
authors.workspace = true
edition.workspace = true
rust-version.workspace = true
# TODO: better description
description = "Recursive voxel game."
# TODO: add homepage = "..." when we have one
repository = "https://github.com/kpreid/all-is-cubes"
repository.workspace = true
license = "MIT OR Apache-2.0"
# TODO: revisit categories once it's more settled what's in this package
categories = ["games", "rendering"]
Expand Down
8 changes: 4 additions & 4 deletions all-is-cubes-gpu/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
[package]
name = "all-is-cubes-gpu"
version = "0.7.0"
authors = ["Kevin Reid <[email protected]>"]
edition = "2021"
rust-version = "1.73"
authors.workspace = true
edition.workspace = true
rust-version.workspace = true
description = "Optional GPU rendering implementation for the all-is-cubes crate."
# TODO: add homepage = "..." when we have one
repository = "https://github.com/kpreid/all-is-cubes"
repository.workspace = true
license = "MIT OR Apache-2.0"
# TODO: revisit categories once it's more settled how useful this is as an engine
categories = ["games", "graphics", "rendering", "rendering::engine"]
Expand Down
8 changes: 4 additions & 4 deletions all-is-cubes-mesh/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
[package]
name = "all-is-cubes-mesh"
version = "0.7.0"
authors = ["Kevin Reid <[email protected]>"]
edition = "2021"
rust-version = "1.73"
authors.workspace = true
edition.workspace = true
rust-version.workspace = true
description = "Mesh generation for the all-is-cubes engine."
# TODO: add homepage = "..." when we have one
repository = "https://github.com/kpreid/all-is-cubes"
repository.workspace = true
license = "MIT OR Apache-2.0"
categories = ["games", "graphics", "rendering"]

Expand Down
8 changes: 4 additions & 4 deletions all-is-cubes-port/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
[package]
name = "all-is-cubes-port"
version = "0.7.0"
authors = ["Kevin Reid <[email protected]>"]
edition = "2021"
rust-version = "1.77"
authors.workspace = true
edition.workspace = true
rust-version.workspace = true
description = "Data import/export for the all-is-cubes engine."
# TODO: add homepage = "..." when we have one
repository = "https://github.com/kpreid/all-is-cubes"
repository.workspace = true
license = "MIT OR Apache-2.0"
categories = ["games", "rendering::data-formats"]

Expand Down
8 changes: 4 additions & 4 deletions all-is-cubes-server/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
[package]
name = "all-is-cubes-server"
version = "0.7.0"
authors = ["Kevin Reid <[email protected]>"]
edition = "2021"
rust-version = "1.73"
authors.workspace = true
edition.workspace = true
rust-version.workspace = true
description = "Game server for the web edition of the recursive voxel game All is Cubes."
# TODO: add homepage = "..." when we have one
repository = "https://github.com/kpreid/all-is-cubes"
repository.workspace = true
license = "MIT OR Apache-2.0"
# TODO: revisit categories once it's more settled what's in this package
categories = ["games"]
Expand Down
8 changes: 4 additions & 4 deletions all-is-cubes-ui/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
[package]
name = "all-is-cubes-ui"
version = "0.7.0"
authors = ["Kevin Reid <[email protected]>"]
edition = "2021"
rust-version = "1.76"
authors.workspace = true
edition.workspace = true
rust-version.workspace = true
description = "User interface subsystem for the all-is-cubes engine."
# TODO: add homepage = "..." when we have one
repository = "https://github.com/kpreid/all-is-cubes"
repository.workspace = true
license = "MIT OR Apache-2.0"
categories = ["games", "gui"]

Expand Down
9 changes: 4 additions & 5 deletions all-is-cubes/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,12 +1,11 @@
[package]
name = "all-is-cubes"
version = "0.7.1"
authors = ["Kevin Reid <[email protected]>"]
edition = "2021"
rust-version = "1.73"
authors.workspace = true
edition.workspace = true
rust-version.workspace = true
repository.workspace = true
description = "Recursive voxel game engine. Can be used for voxel raytracing."
# TODO: add homepage = "..." when we have one
repository = "https://github.com/kpreid/all-is-cubes"
license = "MIT OR Apache-2.0"
# TODO: revisit categories once it's more settled how useful this is as a game engine
categories = ["games", "graphics", "rendering::engine"]
Expand Down
1 change: 0 additions & 1 deletion fuzz/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
name = "all-is-cubes-fuzz"
publish = false
edition = "2021"
rust-version = "1.75"

[package.metadata]
cargo-fuzz = true
Expand Down
6 changes: 3 additions & 3 deletions test-renderers/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
[package]
name = "test-renderers"
authors = ["Kevin Reid <[email protected]>"]
edition = "2021"
rust-version = "1.77"
authors.workspace = true
edition.workspace = true
rust-version.workspace = true
description = "Rendering tests for all-is-cubes."
publish = false

Expand Down
4 changes: 2 additions & 2 deletions tools/xtask/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[package]
name = "xtask"
edition = "2021"
rust-version = "1.75"
edition.workspace = true
rust-version.workspace = true
publish = false

[[bin]]
Expand Down

0 comments on commit f8ad2f8

Please sign in to comment.