diff --git a/Cargo.toml b/Cargo.toml index e2feab1..a4c4776 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -8,3 +8,30 @@ members = [ "rsbinder-tests", "example-hello", ] + +[workspace.package] +version = "0.2.3" +edition = "2021" +license = "Apache-2.0" +homepage = "https://hiking90.github.io/rsbinder-book/" +repository = "https://github.com/hiking90/rsbinder" +rust-version = "1.71" + +[workspace.dependencies] +lazy_static = "1.4" +rsbinder = { version = "0.2.3", path = "rsbinder", default-features = false } +log = "0.4" +env_logger = "0.11" +nix = "0.28" +anstyle = "1.0" +tokio = { version = "1.37", default-features = false } +async-trait = "0.1" +rsbinder-aidl = { version = "0.2.3", path = "rsbinder-aidl", default-features = false } +pest = "2.7" +pest_derive = "2.7" +convert_case = "0.6" +serde = { version = "1.0", features = ["derive"] } +tera = "1.19" +similar = "2.4" +pretty_hex = { version = "0.4", package = "pretty-hex" } +downcast-rs = "1.2" diff --git a/envsetup.sh b/envsetup.sh index a4d5b29..eda2065 100644 --- a/envsetup.sh +++ b/envsetup.sh @@ -139,10 +139,3 @@ function publish() { function publish_dry_run() { publish --dry-run } - -function version_update() { - local NEW_VERSION="$1" - - find . -name "Cargo.toml" -exec sed -i '' "s/^version = \".*\"/version = \"$NEW_VERSION\"/" {} \; - find . -name "Cargo.toml" -exec sed -i '' "/version = \"[^\"]*\", path =/ s/version = \"[^\"]*\"/version = \"$NEW_VERSION\"/" {} \; -} \ No newline at end of file diff --git a/example-hello/Cargo.toml b/example-hello/Cargo.toml index 3c91fc0..60ee0b5 100644 --- a/example-hello/Cargo.toml +++ b/example-hello/Cargo.toml @@ -1,8 +1,8 @@ [package] name = "example-hello" -version = "0.2.3" +version = { workspace = true } publish = false -edition = "2021" +edition = { workspace = true } # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html [features] @@ -11,10 +11,10 @@ sync = ["rsbinder/sync", "rsbinder-aidl/sync"] async = ["rsbinder/async", "rsbinder-aidl/async"] [dependencies] -lazy_static = "1.4" -rsbinder = { version = "0.2.3", path = "../rsbinder", default-features = false } -env_logger = "0.11" -async-trait = "0.1" +lazy_static = { workspace = true } +rsbinder = { workspace = true } +env_logger = { workspace = true } +async-trait = { workspace = true } [build-dependencies] -rsbinder-aidl = { version = "0.2.3", path = "../rsbinder-aidl", default-features = false } +rsbinder-aidl = { workspace = true } diff --git a/rsbinder-aidl/Cargo.toml b/rsbinder-aidl/Cargo.toml index ed395cc..604320a 100644 --- a/rsbinder-aidl/Cargo.toml +++ b/rsbinder-aidl/Cargo.toml @@ -1,13 +1,13 @@ [package] name = "rsbinder-aidl" -version = "0.2.3" -edition = "2021" -license = "Apache-2.0" +version = { workspace = true } +edition = { workspace = true } +license = { workspace = true } description = "This is a AIDL compiler for rsbinder." -homepage = "https://hiking90.github.io/rsbinder-book/" -repository = "https://github.com/hiking90/rsbinder/rsbinder-aidl" +homepage = { workspace = true } +repository = { workspace = true } readme = "README.md" -rust-version = "1.71" +rust-version = { workspace = true } # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html [features] @@ -16,12 +16,12 @@ sync = [] async = [] [dependencies] -pest = "2.7" -pest_derive = "2.7" -convert_case = "0.6" -lazy_static = "1.4" -serde = { version = "1.0", features = ["derive"] } -tera = "1.19" +pest = { workspace = true } +pest_derive = { workspace = true } +convert_case = { workspace = true } +lazy_static = { workspace = true } +serde = { workspace = true } +tera = { workspace = true } [dev-dependencies] -similar = "2.4" +similar = { workspace = true } diff --git a/rsbinder-tests/Cargo.toml b/rsbinder-tests/Cargo.toml index f057bb3..aec1753 100644 --- a/rsbinder-tests/Cargo.toml +++ b/rsbinder-tests/Cargo.toml @@ -1,18 +1,18 @@ [package] name = "rsbinder-tests" -version = "0.2.3" -edition = "2021" +version = { workspace = true } +edition = { workspace = true } publish = false # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html [dependencies] -lazy_static = "1.4" -rsbinder = { version = "0.2.3", path = "../rsbinder" } -tokio = { version = "1.37", features = ["full"] } -env_logger = "0.11" -nix = "0.28" -async-trait = "0.1" +lazy_static = { workspace = true } +rsbinder = { workspace = true } +tokio = { workspace = true } +env_logger = { workspace = true } +nix = { workspace = true } +async-trait = { workspace = true } [build-dependencies] -rsbinder-aidl = { version = "0.2.3", path = "../rsbinder-aidl" } +rsbinder-aidl = { workspace = true } diff --git a/rsbinder-tools/Cargo.toml b/rsbinder-tools/Cargo.toml index eb1d9cf..c7d2c66 100644 --- a/rsbinder-tools/Cargo.toml +++ b/rsbinder-tools/Cargo.toml @@ -1,19 +1,19 @@ [package] name = "rsbinder-tools" -version = "0.2.3" -edition = "2021" -license = "Apache-2.0" +version = { workspace = true } +edition = { workspace = true } +license = { workspace = true } description = "This provides a few CLI binder tools for Linux." -homepage = "https://hiking90.github.io/rsbinder-book/" -repository = "https://github.com/hiking90/rsbinder/rsbinder-tools" +homepage = { workspace = true } +repository = { workspace = true } readme = "README.md" # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html [dependencies] -lazy_static = "1.4" -rsbinder = { version = "0.2.3", path = "../rsbinder" } -log = "0.4" -env_logger = "0.11" -nix = "0.28" -anstyle = "1.0" +lazy_static = { workspace = true } +rsbinder = { workspace = true } +log = { workspace = true } +env_logger = { workspace = true } +nix = { workspace = true } +anstyle = { workspace = true } diff --git a/rsbinder/Cargo.toml b/rsbinder/Cargo.toml index 8d7aaf4..9b4e9ad 100644 --- a/rsbinder/Cargo.toml +++ b/rsbinder/Cargo.toml @@ -1,13 +1,13 @@ [package] name = "rsbinder" -version = "0.2.3" -edition = "2021" -license = "Apache-2.0" +version = { workspace = true } +edition = { workspace = true } +license = { workspace = true } description = "This is a library for Linux Binder communication." -homepage = "https://hiking90.github.io/rsbinder-book/" -repository = "https://github.com/hiking90/rsbinder" +homepage = { workspace = true } +repository = { workspace = true } readme = "README.md" -rust-version = "1.71" +rust-version = { workspace = true } # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html @@ -18,16 +18,16 @@ tokio = ["async", "tokio/full"] async = ["rsbinder-aidl/async", "async-trait"] [dependencies] -nix = { version = "0.28", features = ["ioctl", "mount", "fs", "feature", "mman", "process"] } -log = "0.4" -pretty_hex = { version = "0.4", package = "pretty-hex" } -downcast-rs = "1.2" -async-trait = { version = "0.1", optional = true } -lazy_static = "1.4" -tokio = { version = "1.37", optional = true, default-features = false } +nix = { workspace = true, features = ["ioctl", "mount", "fs", "feature", "mman", "process"] } +log = { workspace = true } +pretty_hex = { workspace = true } +downcast-rs = { workspace = true } +async-trait = { workspace = true, optional = true } +lazy_static = { workspace = true } +tokio = { workspace = true, optional = true } [build-dependencies] -rsbinder-aidl = { version = "0.2.3", path = "../rsbinder-aidl", default-features = false } +rsbinder-aidl = { workspace = true } [dev-dependencies] -env_logger = "0.11" +env_logger = { workspace = true }