PdfCraft: An open-source PDF reader and editor written by scratch in pure Rust
Raise workspace rust-version to 1.95 to match the UI crate (#1169) (#1188)
MarekSpodBiedry75b113ac5be2
diff --git a/Cargo.toml b/Cargo.tomlindex 70a65b6b9..ddea910f4 100644--- a/Cargo.toml+++ b/Cargo.toml@@ -8,7 +8,7 @@ default-members = ["crates/*", "apps/pdfcraft", "apps/pdfcraft-cli", "xtask"]version = "0.6.0"edition = "2024"license = "MIT OR Apache-2.0"-rust-version = "1.90"+rust-version = "1.95"repository = "https://github.com/storytold/pdfcraft"[workspace.dependencies]diff --git a/README.md b/README.mdindex a0e985b1a..4f5792db9 100644--- a/README.md+++ b/README.md@@ -369,6 +369,8 @@ PdfCraft is a clean-room implementation. Its behaviour comes from the ISO 32000## Get started+Building needs Rust 1.95 or later.+```shgit clone https://github.com/storytold/pdfcraftcd pdfcraftdiff --git a/docs/architecture.md b/docs/architecture.mdindex eb56cdb3e..013633b77 100644--- a/docs/architecture.md+++ b/docs/architecture.md@@ -8,7 +8,7 @@ crate's `README.md` has the detail.## Shape-One Cargo workspace (`Cargo.toml`, edition 2024, Rust ≥ 1.90, `MIT OR Apache-2.0`), 31 library+One Cargo workspace (`Cargo.toml`, edition 2024, Rust ≥ 1.95, `MIT OR Apache-2.0`), 31 librarycrates in `crates/`, three binaries in `apps/`, build tooling in `xtask/`, and patched third-partycrates in `vendor/`. About 152k lines of Rust and 1,765 tests (2026-10-10). Rust only: nohandwritten JS/TS, in the product or the build.diff --git a/docs/development.md b/docs/development.mdindex 535311891..634c4bb26 100644--- a/docs/development.md+++ b/docs/development.md@@ -22,8 +22,8 @@ Cargo stores custom-profile artifacts separately under `target/low-disk`. Switchnormal and low-disk profiles can therefore leave both sets of artifacts on disk. To remove onlythe low-disk artifacts, run `cargo clean --profile low-disk`.-The UI crate and complete desktop/web builds require Rust 1.95 or later, matching the pinned-`craft-ui` dependency. The workspace's core-crate minimum is unchanged.+Building PdfCraft requires Rust 1.95 or later: the UI crate and its `egui` and `craft-ui`+dependencies need it, and the workspace `rust-version` states the same minimum.## Interface appearancediff --git a/xtask/src/version.rs b/xtask/src/version.rsindex e11c99d76..067365317 100644--- a/xtask/src/version.rs+++ b/xtask/src/version.rs@@ -154,4 +154,18 @@ mod tests {let text = std::fs::read_to_string(crate::gates::root().join("Cargo.toml")).unwrap();validate(&read(&text).unwrap()).unwrap();}++ /// The `rust-version = "1.NN"` line of a manifest, as the minor number.+ fn minor_of_rust_version(manifest: &str) -> u32 {+ let line = manifest.lines().find(|l| l.starts_with("rust-version = \"")).unwrap();+ line.split('"').nth(1).unwrap().split('.').nth(1).unwrap().parse().unwrap()+ }++ #[test]+ fn workspace_rust_version_covers_the_ui_crate() {+ let root = crate::gates::root();+ let workspace = std::fs::read_to_string(root.join("Cargo.toml")).unwrap();+ let ui = std::fs::read_to_string(root.join("crates/ui-egui/Cargo.toml")).unwrap();+ assert!(minor_of_rust_version(&workspace) >= minor_of_rust_version(&ui));+ }}