#4958·antlr4

Code is regenerated all the time

Author: vborovikovCreated Jul 20, 2026Updated Jul 20, 2026

Is there a way to disable this line in the generated output of the tool?

https://github.com/antlr/antlr4/blob/7d5770395bb7b02eb56e7c62662cb1d7c08f42a3/tool/resources/org/antlr/v4/tool/templates/codegen/CSharp/CSharp.stg#L254

Each time I open the project from a new branch the files are regenerated and that path is always different from the committed version so git marks the generated files as modified. It's very annoying.

.NET 10, Antlr4.Runtime.Standard v4.13.1, Antlr4BuildTasks v12.14.0

Maybe Antlr4BuildTasks has a parameter not to generate the files all the time?