From 58613a61f3d6ef5ac1d0773c508b68fb6375fbfa Mon Sep 17 00:00:00 2001 From: Adam Poulemanos Date: Sat, 25 Jul 2026 21:55:49 -0400 Subject: [PATCH 1/3] chore: fix typos, clippy idioms, and formatting after P2/P3 test work Follow-up polish on the P2/P3 test-improvement work (#62) that landed in ffe76d8 and 1c22370: - Spelling: "behaviour" -> "behavior" in CLI help, doc comments, and the README, matching the en-us locale declared in _typos.toml. - Clippy idioms: map(..).unwrap_or(false) -> is_ok_and, map(to_string) -> map(clone) on an owned String. - rustfmt over the test files touched by the P3 work. - _typos.toml: recognize the HTML comment form of the spellchecker:off/on fence, and exclude the generated CHANGELOG.md. - hk.pkl: drop the redundant --config flag from the typos step; typos already discovers _typos.toml from the workspace indicator. Refs #62 Co-Authored-By: Claude Opus 5 Claude-Session: https://claude.ai/code/session_01XocU6NjgZricrRWMLyLXDn --- README.md | 2 +- _typos.toml | 5 ++- hk.pkl | 4 +- src/commands.rs | 6 +-- src/config.rs | 4 +- src/git_manager.rs | 22 ++++++----- src/git_ops/git2_ops.rs | 14 +++++-- src/git_ops/gix_ops.rs | 4 +- src/git_ops/simple_gix.rs | 2 +- src/options.rs | 2 +- src/utilities.rs | 29 +++++++++----- tests/config_tests.rs | 74 ++++++++++++++++++++++++----------- tests/error_handling_tests.rs | 12 ++++-- tests/performance_tests.rs | 65 +++++++++++++++++++----------- tests/security_tests.rs | 38 ++++++++++-------- 15 files changed, 182 insertions(+), 101 deletions(-) diff --git a/README.md b/README.md index 52863c7..245ac91 100644 --- a/README.md +++ b/README.md @@ -319,7 +319,7 @@ submod completeme bash > ~/.bash_completion.d/submod ```zsh "zsh" # zsh has an fpath array with possible function directories. You can -# put your competions in any of these; we use the first one here: +# put your completions in any of these; we use the first one here: ZSH_DEFAULT="${XDG_DATA_HOME:-~/.local/share}/zsh/site-functions" ZFUNCDIR=""${fpath[1]:-$ZSH_DEFAULT}" mkdir -p "$ZFUNCDIR" diff --git a/_typos.toml b/_typos.toml index 1ec392d..5064868 100755 --- a/_typos.toml +++ b/_typos.toml @@ -7,7 +7,7 @@ locale = "en-us" check-file = true check-filename = true extend-ignore-re = [ - "(?s)(#|//)\\s*spellchecker:off.*?\\n\\s*(#|//)\\s*spellchecker:on" + "(?s)(#|//|