From 47f55105ddae1d3df2f373e25aabd2b6ba7e84a7 Mon Sep 17 00:00:00 2001 From: 2ndbeam <2ndbeam@disroot.org> Date: Thu, 4 Dec 2025 13:56:53 +0300 Subject: [PATCH] refactor!: Moved CLI to inner package - Increased version to 0.3.0 - Repository now is a Cargo workspace - Added squad-quest-cli package - Removed CLI-specific dependencies from main crate - Removed bin target from main package --- .gitignore | 1 + Cargo.lock | 12 ++++++++++-- Cargo.toml | 18 +++++++++++++----- cli/Cargo.toml | 13 +++++++++++++ src/bin/cli.rs => cli/src/main.rs | 0 5 files changed, 37 insertions(+), 7 deletions(-) create mode 100644 cli/Cargo.toml rename src/bin/cli.rs => cli/src/main.rs (100%) diff --git a/.gitignore b/.gitignore index ea8c4bf..f20fcf9 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,2 @@ /target +/cli/target diff --git a/Cargo.lock b/Cargo.lock index 1c88b30..d263382 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -332,12 +332,20 @@ checksum = "0fda2ff0d084019ba4d7c6f371c95d8fd75ce3524c3cb8fb653a3023f6323e64" [[package]] name = "squad-quest" -version = "0.2.0" +version = "0.3.0" +dependencies = [ + "serde", + "toml", +] + +[[package]] +name = "squad-quest-cli" +version = "0.3.0" dependencies = [ "chrono", "clap", - "clap_derive", "serde", + "squad-quest", "toml", ] diff --git a/Cargo.toml b/Cargo.toml index f912a91..669dcea 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,11 +1,19 @@ +[workspace] +members = ["cli"] + +[workspace.package] +version = "0.3.0" +edition = "2024" +repository = "https://2ndbeam.ru/git/2ndbeam/squad-quest" +license = "MIT" + [package] name = "squad-quest" -version = "0.2.0" -edition = "2024" +edition.workspace = true +version.workspace = true +repository.workspace = true +license.workspace = true [dependencies] -chrono = "0.4.42" -clap = { version = "4.5.53", features = ["derive"] } -clap_derive = "4.5.49" serde = { version = "1.0.228", features = ["derive"] } toml = "0.9.8" diff --git a/cli/Cargo.toml b/cli/Cargo.toml new file mode 100644 index 0000000..2612f50 --- /dev/null +++ b/cli/Cargo.toml @@ -0,0 +1,13 @@ +[package] +name = "squad-quest-cli" +version.workspace = true +edition.workspace = true +repository.workspace = true +license.workspace = true + +[dependencies] +chrono = "0.4.42" +clap = { version = "4.5.53", features = ["derive"] } +serde = { version = "1.0.228", features = ["derive"] } +squad-quest = { version = "0.3.0", path = ".." } +toml = "0.9.8" diff --git a/src/bin/cli.rs b/cli/src/main.rs similarity index 100% rename from src/bin/cli.rs rename to cli/src/main.rs