You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
#1331 added LfNormalizingFileSystemAccess and wired it into CheckGenerator and CheckCfgGenerator so generated output is LF regardless of host OS. The same risk pattern exists in three other runtime IGenerator/IGenerator2 classes that emit Java sources to committed src-gen/ directories — they were not addressed in #1331.
Plus an FSA-bypass writer that needs separate handling:
KeywordAnalysisHelper uses raw PrintWriter (.println() → platform line separator) at lines 183, 444, 448 — writes report and documentation files to srcGenPath. The decorator-wrapper approach doesn't apply here; fix is either explicit \n or a BufferedWriter with explicit LF.
Why this matters
.gitattributes (* text=auto eol=lf) normalizes on commit, so the committed state and the line-endings CI check stay green. The value is preventing working-tree noise for Windows developers: after regeneration, every file shows as modified in git status/git diff due to EOL drift relative to the index.
Suggested approach
Hoist LfNormalizingFileSystemAccess from com.avaloq.tools.ddk.check.core to a shared bundle (e.g. com.avaloq.tools.ddk.xtext) so the three generators above can depend on it without pulling in check.core.
Context
#1331 added
LfNormalizingFileSystemAccessand wired it intoCheckGeneratorandCheckCfgGeneratorso generated output is LF regardless of host OS. The same risk pattern exists in three other runtimeIGenerator/IGenerator2classes that emit Java sources to committedsrc-gen/directories — they were not addressed in #1331.Generators with the same risk
ScopeGeneratorcom.avaloq.tools.ddk.xtext.scopedoGenerate(Resource, IFileSystemAccess2, IGeneratorContext)FormatGeneratorcom.avaloq.tools.ddk.xtext.formatdoGenerate(Resource, IFileSystemAccess)ExportGeneratorcom.avaloq.tools.ddk.xtext.exportdoGenerate(Resource, IFileSystemAccess2, IGeneratorContext)(8generateFilecall sites)Plus an FSA-bypass writer that needs separate handling:
KeywordAnalysisHelperuses rawPrintWriter(.println()→ platform line separator) at lines 183, 444, 448 — writes report and documentation files tosrcGenPath. The decorator-wrapper approach doesn't apply here; fix is either explicit\nor aBufferedWriterwith explicit LF.Why this matters
.gitattributes(* text=auto eol=lf) normalizes on commit, so the committed state and the line-endings CI check stay green. The value is preventing working-tree noise for Windows developers: after regeneration, every file shows as modified ingit status/git diffdue to EOL drift relative to the index.Suggested approach
LfNormalizingFileSystemAccessfromcom.avaloq.tools.ddk.check.coreto a shared bundle (e.g.com.avaloq.tools.ddk.xtext) so the three generators above can depend on it without pulling incheck.core.doGenerate(...)in the same pattern as fix: normalize line endings in check generators #1331.KeywordAnalysisHelperis in scope — if yes, fix via explicit\nrather than the wrapper.Out of scope
*Fragment2classes (build-time workflow only, route through Xtext'sIXtextGeneratorFileSystemAccess— separate path).TestLanguageGenerator) — their output isn't committed.Left by Claude at João's request.