From 586957ec247a2a10c7c9691cefb78fcdf01cf5d5 Mon Sep 17 00:00:00 2001 From: Ken Tobias <634380+l1a@users.noreply.github.com> Date: Sat, 8 Aug 2026 22:24:58 -0700 Subject: [PATCH] Bump 4 deps and fix man page font-run strip MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Consolidates Dependabot #182 onto a gated branch so the release-hygiene steps Dependabot skips (version bump, NOTES entry, man regen) are done. Dependencies (cargo-dependencies group, lockfile-only — every spec is a caret range, so Cargo.toml is untouched): clap 4.6.4 -> 4.6.5 (clap_builder 4.6.2 -> 4.6.5) toml 1.1.3 -> 1.1.4 (toml_parser 1.1.2 -> 1.1.3) clap_complete 4.6.7 -> 4.6.8 base64 0.23.0 -> 0.23.1 The resulting Cargo.lock is byte-identical to what Dependabot generated. Also fixes the `just man` font-collapsing sed, which has never worked on any platform. mandown emits redundant \fB\fB...\fP\fP runs and the recipe carried `s/\fB\fB/\fB/g` to strip them, but GNU sed reads \f as the form-feed escape rather than backslash-then-f, so the pattern only ever matched form feeds that groff output never contains. This is why docs/retch.1 kept flip-flopping between machines: v0.6.2 concluded the strip merely "didn't take effect on Windows", when in fact Linux was not stripping anything either — its mandown build just doesn't emit the doubled runs. Matching the backslash as [\] and carrying it out through a capture group keeps any backslash escape off the replacement side. With the fix, `just man` on Windows reproduces byte-for-byte the file a Linux `just man` produces, so the regen check in `just pr` no longer depends on which machine last ran it. The regenerated page drops 21 doubled font runs and changes nothing else but the version footer. retch-sysinfo unchanged at 0.1.51; no Rust source touched. Assisted-By: Claude Opus 5 --- Cargo.lock | 26 +++++++++++++------------- Cargo.toml | 2 +- Justfile | 8 +++++++- NOTES.md | 41 ++++++++++++++++++++++++++++++++++++++++- docs/retch.1 | 44 ++++++++++++++++++++++---------------------- 5 files changed, 83 insertions(+), 38 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 8b44356..b15a237 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -198,9 +198,9 @@ dependencies = [ [[package]] name = "base64" -version = "0.23.0" +version = "0.23.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b25655df2c3cdd83c5e5b293b88acd880332b2ddadd7c30ac43144fdc0033da9" +checksum = "ac07cdecf99051d9a5238b80f35af32cdeba5b336e55d957b318b50137e18da5" [[package]] name = "bit_field" @@ -345,9 +345,9 @@ dependencies = [ [[package]] name = "clap" -version = "4.6.4" +version = "4.6.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d91e0c145792ef73a6ad36d27c75ac09f1832222a3c209689d90f534685ee5b7" +checksum = "301b56658598e48f3648647ac6fc887be7e7108eddfa4e9b63fcf3ec58c0cadf" dependencies = [ "clap_builder", "clap_derive", @@ -355,9 +355,9 @@ dependencies = [ [[package]] name = "clap_builder" -version = "4.6.2" +version = "4.6.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f09628afdcc538b57f3c6341e9c8e9970f18e4a481690a64974d7023bd33548b" +checksum = "94a65403d1a1bd28f7dc68eb8506e8874808ee5eecb59298de588e2e1407a078" dependencies = [ "anstream", "anstyle", @@ -367,9 +367,9 @@ dependencies = [ [[package]] name = "clap_complete" -version = "4.6.7" +version = "4.6.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "db8b397918185f0161ff3d6fcaa9e4bfc09b8367caf6e1d4a2848e5477ed027b" +checksum = "b1f84a88507dbd05c695f2cb5e8558e747179134005e9893882dec964190ed89" dependencies = [ "clap", ] @@ -1551,7 +1551,7 @@ checksum = "dc897dd8d9e8bd1ed8cdad82b5966c3e0ecae09fb1907d58efaa013543185d0a" [[package]] name = "retch-cli" -version = "0.6.15" +version = "0.6.16" dependencies = [ "anyhow", "base64", @@ -1860,9 +1860,9 @@ dependencies = [ [[package]] name = "toml" -version = "1.1.3+spec-1.1.0" +version = "1.1.4+spec-1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "53c96ecdfa941c8fc4fcaed14f99ada8ebed502eef533015095a07e3301d4c3c" +checksum = "3aace63f4bbcdfc2c965b059de67119c89c4017a70d633be6c104910f67056f5" dependencies = [ "indexmap", "serde_core", @@ -1884,9 +1884,9 @@ dependencies = [ [[package]] name = "toml_parser" -version = "1.1.2+spec-1.1.0" +version = "1.1.3+spec-1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a2abe9b86193656635d2411dc43050282ca48aa31c2451210f4202550afb7526" +checksum = "1d38ac1cf9b95face32296c0a3ede1fdc270627c9d9c02a7274dd6d960dc4d56" dependencies = [ "winnow", ] diff --git a/Cargo.toml b/Cargo.toml index bc328bc..11bc255 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -6,7 +6,7 @@ members = [ [package] name = "retch-cli" -version = "0.6.15" +version = "0.6.16" edition = "2021" authors = ["Ken Tobias"] description = "A fast, feature-rich system information fetcher written in Rust (similar to fastfetch or neofetch)" diff --git a/Justfile b/Justfile index 9082582..5023d33 100644 --- a/Justfile +++ b/Justfile @@ -63,11 +63,17 @@ install: install-man install-completions # Generate man page from Markdown using mandown. # The version is dynamically read from Cargo.toml and placed in the footer. +# The two font-collapsing seds drop mandown's redundant `\fB\fB…\fP\fP` runs. They match the +# backslash as `[\]` and carry it out through a capture group deliberately: the obvious +# `s/\\fB\\fB/\\fB/g` is silently a no-op, because GNU sed reads `\\f` as the form-feed escape +# rather than backslash-then-f, so it only ever matches form feeds groff output never contains +# (and would emit one if it did). That no-op is why docs/retch.1 kept flip-flopping between +# machines depending on which mandown build wrote it. man: @mkdir -p docs @VERSION=$(grep '^version' Cargo.toml | head -1 | cut -d '"' -f2); \ DATE=$(date +"%B %Y"); \ - mandown docs/retch.1.md RETCH 1 | sed -e 's/\\fB\\fB/\\fB/g' -e 's/\\fP\\fP/\\fP/g' -e "s/\\.TH \"RETCH\" 1/\\.TH \"RETCH\" \"1\" \"$DATE\" \"retch $VERSION\" \"System Information Fetcher\"/" > docs/retch.1 + mandown docs/retch.1.md RETCH 1 | sed -e 's/[\]fB\([\]fB\)/\1/g' -e 's/[\]fP\([\]fP\)/\1/g' -e "s/\\.TH \"RETCH\" 1/\\.TH \"RETCH\" \"1\" \"$DATE\" \"retch $VERSION\" \"System Information Fetcher\"/" > docs/retch.1 diff --git a/NOTES.md b/NOTES.md index 3bf9eca..992aff7 100644 --- a/NOTES.md +++ b/NOTES.md @@ -96,7 +96,39 @@ The `retch-sysinfo` crate can be used independently as a library for cross-platf --- -## Current State (v0.6.15) +## Current State (v0.6.16) +- **v0.6.16 — dependency bumps (consolidated Dependabot #182) + the man-page font-run fix + that has been flip-flopping `docs/retch.1` between machines** (chore; no runtime behavior + change, `retch-sysinfo` unchanged at `0.1.51`). + - **4 Rust crates** (`cargo-dependencies` group, #182), all patch-level and lockfile-only — + every spec is a caret range, so `Cargo.toml` is untouched: `clap` 4.6.4→4.6.5 (pulls + `clap_builder` 4.6.2→4.6.5), `toml` 1.1.3→1.1.4 (pulls `toml_parser` 1.1.2→1.1.3), + `clap_complete` 4.6.7→4.6.8, `base64` 0.23.0→0.23.1. The resulting `Cargo.lock` was + diff-verified byte-identical to what Dependabot generated on #182. `base64` is + graphics-feature-only, so `just check`'s `--features graphics` clippy pass (v0.6.5) is the + leg that actually exercises it; the CI `graphics-feature` job (v0.6.7) covers the same + ground and was green on #182 before the consolidation. + - **The `just man` font-collapsing sed has never worked, on any platform** — root-caused + here, which closes the question v0.6.2 left open as "not reproducible without a Windows + box". `mandown` emits redundant `\fB\fB…\fP\fP` runs and the recipe carried + `sed -e 's/\\fB\\fB/\\fB/g' -e 's/\\fP\\fP/\\fP/g'` to strip them. **GNU sed reads `\\f` + as the form-feed escape, not backslash-then-`f`**, so the pattern only ever matched form + feeds — which groff output never contains — and the replacement would have *emitted* a + form feed had it matched. Confirmed against GNU sed 4.9 with a minimal fixture + (`\fB\fB\-h\fP\fP` in, unchanged out). So v0.6.2's conclusion that "Linux output is + canonical" was right about *which bytes to keep* but wrong about *why*: Linux was not + stripping anything either — its `mandown` build simply doesn't emit the doubled runs, so + the difference was never the `sed` "not taking effect on Windows", it was two mandown + builds and a strip that was dead code everywhere. Fixed by matching the backslash as + `[\]` and carrying it out through a capture group (`s/[\]fB\([\]fB\)/\1/g`), so no + backslash escape appears on the replacement side at all. **Verified byte-identical**: with + the fix, `just man` on Windows reproduces exactly the file a Linux `just man` produces, so + `just pr`'s regen check no longer flips depending on which machine last ran it. The + regenerated page drops 21 doubled font runs and changes nothing else but the version + footer (proved by normalising HEAD's page through the same collapse and diffing). + - No Rust source touched, so there is nothing for `cargo test` to cover; the Justfile fix is + verified by direct execution and byte-comparison (same approach as v0.6.13's Python + helpers). `retch-cli` → 0.6.16. Patch bump. - **v0.6.15 — Windows `Display` monitor model EDID parsing parity** (`crates/sysinfo/src/display.rs`, `crates/sysinfo/src/win_reg.rs`). On Windows, `detect_displays` now enumerates monitor devices attached to active display adapters (`EnumDisplayDevicesW`), queries registry `HKLM\SYSTEM\CurrentControlSet\Enum\DISPLAY\\\Device Parameters`, and parses raw binary `"EDID"` blobs via `parse_monitor_name_from_edid`. This outputs actual display brand and model names (e.g. `ATNA33AA08-0 (2880x1800 @ 60Hz)`) instead of falling back to GPU adapter names (`AMD Radeon(TM) 8060S Graphics`). Added `get_reg_bytes` binary reader in `win_reg.rs`. Tested live on arrakis. `retch-sysinfo` → `0.1.51`; `retch-cli` → `0.6.15`. Patch bump. - **v0.6.14 — Windows `Domain` & `Domain Search` parity fix** (cross-platform parity fix, `crates/sysinfo/src/network.rs`). @@ -397,6 +429,13 @@ The `retch-sysinfo` crate can be used independently as a library for cross-platf the Linux output is canonical. **Cross-machine caveat:** a future Windows `just man` may re-introduce the double-bold diff; the next Windows session should regenerate and expect the single-bold form (tracked in WIP.md). + - **RESOLVED in v0.6.16 — and the diagnosis above is wrong on the mechanism.** The + caveat came true (v0.6.15 was generated on Windows and committed a double-bold page), + and root-causing it showed the strip was never "not taking effect on Windows": the sed + is a no-op on *every* platform, because GNU sed reads `\\f` as a form feed. Linux's + page was single-bold only because its `mandown` build does not emit the doubled runs. + See the v0.6.16 entry; the recipe now strips correctly and both platforms produce + identical bytes. - Patch bump. `retch-sysinfo` → `0.1.46` (new `pub parse_xrandr_displays_with`). - **v0.6.1 — fix two Windows output bugs: `Camera` listing scanners, `Users` = 0** (Windows cross-platform-parity series, bugfix group): diff --git a/docs/retch.1 b/docs/retch.1 index 23e30de..8f77158 100644 --- a/docs/retch.1 +++ b/docs/retch.1 @@ -1,4 +1,4 @@ -.TH "RETCH" "1" "August 2026" "retch 0.6.15" "System Information Fetcher" +.TH "RETCH" "1" "August 2026" "retch 0.6.16" "System Information Fetcher" .SH "NAME" .PP @@ -13,87 +13,87 @@ retch \- a fast, feature\-rich system information fetcher \fBretch\fP is a fast system information tool written in Rust\. It displays detailed information about your system including OS, CPU, memory, audio, disks, network, Wi\-Fi, Bluetooth, and more, with support for high\-quality ASCII and graphical logos\. .SH "OPTIONS" -\fB\fB\-h, \-\-help\fP\fP +\fB\-h, \-\-help\fP .RS Show help information\. .RE -\fB\fB\-V, \-\-version\fP\fP +\fB\-V, \-\-version\fP .RS Print version information\. .RE -\fB\fB\-m, \-\-mode\fP \fIMODE\fP\fP +\fB\-m, \-\-mode\fP \fIMODE\fP .RS Select output mode (`\f[CR]short\fP`, `\f[CR]long\fP`, or `\f[CR]custom\fP`)\. .RE -\fB\fB\-c, \-\-config\fP \fIFILE\fP\fP +\fB\-c, \-\-config\fP \fIFILE\fP .RS Path to a custom configuration file instead of the default\. .RE -\fB\fB\-\-ascii\-logo\fP\fP +\fB\-\-ascii\-logo\fP .RS Force ASCII logo output, disabling graphical and Chafa rendering\. .RE -\fB\fB\-\-chafa\-logo\fP\fP +\fB\-\-chafa\-logo\fP .RS Force Chafa symbols output, disabling high\-res graphical protocols (Kitty, Sixel, iTerm2)\. .RE -\fB\fB\-\-no\-logo\fP\fP +\fB\-\-no\-logo\fP .RS Disable the logo entirely\. .RE -\fB\fB\-\-logo\fP \fILOGO\fP\fP +\fB\-\-logo\fP \fILOGO\fP .RS Force a specific distribution logo by name/ID (e\.g\. `\f[CR]pop\fP`, `\f[CR]manjaro\fP`, `\f[CR]endeavouros\fP`, `\f[CR]opensuse\fP`, `\f[CR]ubuntu\fP`, `\f[CR]fedora\fP`, `\f[CR]macos\fP`, `\f[CR]windows\fP`)\. .RE -\fB\fB\-\-theme\fP \fITHEME\fP\fP +\fB\-\-theme\fP \fITHEME\fP .RS Use a specific theme (e\.g\. `\f[CR]default\fP`, `\f[CR]dark\fP`, `\f[CR]light\fP`, or community themes)\. .RE -\fB\fB\-\-list\-themes\fP\fP +\fB\-\-list\-themes\fP .RS List all available built\-in themes\. .RE -\fB\fB\-\-print\-theme\-template\fP\fP +\fB\-\-print\-theme\-template\fP .RS Print an example custom theme template to stdout\. .RE -\fB\fB\-\-print\-logos\fP\fP +\fB\-\-print\-logos\fP .RS Print all available logos\. .RE -\fB\fB\-\-list\-distros\fP\fP +\fB\-\-list\-distros\fP .RS List known supported distributions\. .RE -\fB\fB\-\-completions\fP \fISHELL\fP\fP +\fB\-\-completions\fP \fISHELL\fP .RS Generate shell completion scripts for the specified shell\. Supported shells are: `\f[CR]bash\fP`, `\f[CR]elvish\fP`, `\f[CR]fish\fP`, `\f[CR]power\-shell\fP`, `\f[CR]zsh\fP`, `\f[CR]nushell\fP`\. .RE -\fB\fB\-\-generate\-config\fP\fP +\fB\-\-generate\-config\fP .RS Print a default configuration file to stdout\. .RE -\fB\fB\-\-write\-config\fP [\fIPATH\fP]\fP +\fB\-\-write\-config\fP [\fIPATH\fP]\fP .RS Write the default configuration to a file (uses `\f[CR]~/\.config/retch/config\.toml\fP` if no path is given)\. .RE -\fB\fB\-\-merge\-config\fP\fP +\fB\-\-merge\-config\fP .RS Merge default configuration settings (as comments) into an existing config file at the default path (or custom path if `\f[CR]\-\-config\fP` is supplied)\. .RE -\fB\fB\-\-fields\fP \fIFIELDS\fP\fP +\fB\-\-fields\fP \fIFIELDS\fP .RS Comma\-separated list of fields to display, overriding the config file's default list\. .RE -\fB\fB\-s, \-\-short\fP\fP +\fB\-s, \-\-short\fP .RS Short output mode\. Equivalent to `\f[CR]\-\-mode short\fP`\. Shows: OS, Kernel, Host, CPU, GPU, Memory, Disk\. .RE -\fB\fB\-l, \-\-long\fP\fP +\fB\-l, \-\-long\fP .RS Long output mode\. Shows diagnostics fields \-\- firmware, thermals (consolidated: one reading per physical unit), shell, desktop, network, Bluetooth, battery, packages, and more\. Does not include cosmetic or slow\-running fields (use `\f[CR]\-\-full\fP` for those)\. .RE -\fB\fB\-f, \-\-full\fP\fP +\fB\-f, \-\-full\fP .RS Full output mode\. Shows everything in `\f[CR]\-\-long\fP` plus slow and cosmetic fields: UI theme, icons, cursor, weather (requires network), and FUSE mounts\. Expect multi\-second runtimes\. .RE