Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.Sign up
proposal: cmd/go: 'go mod tidy' should remove stale 'replace' directives #30516
What version of Go are you using (
In general we don't override grouping. If you wrote three replace lines, they should stay three separate replace lines. (Especially if there are comments involved, but even if not.)
I will retitle this to be about unused replaces, which are not as clearly off the table. It's tied up with #29813, though, and in general I'm hesitant to make tidy throw away info that might be needed.