diff --git a/src/omind/guard.py b/src/omind/guard.py index 777e61c..f3facc6 100644 --- a/src/omind/guard.py +++ b/src/omind/guard.py @@ -63,13 +63,16 @@ "this turn; a generic project-memory consult is not enough." ) GIT_FRESHNESS_MESSAGE = ( - "repo work requires a same-turn freshness check before review/edit/test/commit/push. " - "Put a LITERAL-path fetch in the SAME command as the write, chained with && — e.g.:\n" - ' git -C "/abs/path/to/repo" fetch --all --prune && git -C "/abs/path/to/repo" commit -am "..."\n' - "(same shape for push / a git write; for `gh pr create`, prefix it with the literal-path fetch too). " - "Gotchas that make it silently fail: (1) the path must be a LITERAL absolute path — a $VAR is not " - "resolved by the static parser; (2) no pipe/redirect in the fetch part; (3) the fetch must succeed " - "(exit 0) — if `--all` hits an unreachable mirror (e.g. a Codeberg remote with no key loaded), use " + "repo work requires a same-turn freshness check before " + "review/edit/test/commit/push. Put a LITERAL-path fetch in the SAME command as " + "the write, chained with && — e.g.:\n" + ' git -C "/abs/path/to/repo" fetch --all --prune ' + '&& git -C "/abs/path/to/repo" commit -am "..."\n' + "(same shape for push / a git write; for `gh pr create`, prefix it with the " + "literal-path fetch too). Gotchas that make it silently fail: (1) the path must " + "be a LITERAL absolute path — a $VAR is not resolved by the static parser; (2) no " + "pipe/redirect in the fetch part; (3) the fetch must succeed (exit 0) — if `--all` " + "hits an unreachable mirror (e.g. a Codeberg remote with no key loaded), use " "`fetch origin --prune` so it doesn't error out and fail to register." ) GLOBAL_MUTATION_MESSAGE = (