From 84daa0b8be2f53d212cd86fccb986fd1967a8350 Mon Sep 17 00:00:00 2001 From: silverwind Date: Sun, 29 Mar 2026 00:44:17 +0100 Subject: [PATCH] Update AGENTS.md with additional guidelines (#37018) Add and modify more instruction for common problems in this codebase and made the force-push instruction more strict. --------- Signed-off-by: silverwind Co-authored-by: Claude (Opus 4.6) --- AGENTS.md | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/AGENTS.md b/AGENTS.md index 3db66637b7..589dea7865 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -4,5 +4,8 @@ - Run `make tidy` after any `go.mod` changes - Add the current year into the copyright header of new `.go` files - Ensure no trailing whitespace in edited files -- Never force-push to pull request branches -- Always start issue and pull request comments with an authorship attribution +- Never force-push, amend, or squash unless asked. Use new commits and normal push for pull request updates +- Preserve existing code comments, do not remove or rewrite comments that are still relevant +- In TypeScript, use `!` (non-null assertion) instead of `?.`/`??` when a value is known to always exist +- Include authorship attribution in issue and pull request comments +- Add `Co-Authored-By` lines to all commits, indicating name and model used