Skip to content

chore: emit LF from MWE2 code generation#1413

Open
joaodinissf wants to merge 1 commit into
dsldevkit:masterfrom
joaodinissf:chore/emit-lf-config
Open

chore: emit LF from MWE2 code generation#1413
joaodinissf wants to merge 1 commit into
dsldevkit:masterfrom
joaodinissf:chore/emit-lf-config

Conversation

@joaodinissf

Copy link
Copy Markdown
Collaborator

Aligns code generation with the repository's line-ending policy (.gitattributes * text=auto eol=lf + the line-endings CI check). Nine lines, no regeneration. Refs #1345.

What changes

  • lineDelimiter = "\n" in all seven MWE2 workflows (was "\r\n"). Regenerated src-gen then matches the checkout byte-for-byte instead of relying on git's index normalization to hide the difference.
  • line.separator=\n in ddk-configuration/.settings/org.eclipse.core.runtime.prefs. This file is not project-local config: 56 of the 64 com.avaloq.tools.ddk* projects link it into their own .settings via .project linkedResources, so it governs what Eclipse writes across essentially the whole workspace.
  • preferXtendStubs = false for the FormatterTestLanguage workflow only: its stub classes exist as handwritten .java files in xtext.test, and the generator's stub-existence check is exact-path/exact-flavor — with the default it misses the .java twins and resurrects .xtend duplicates that were deliberately deleted in 2024. The other workflows keep the default, which is load-bearing for the format bundle's handwritten .xtend stubs.

What deliberately does not change

  • No regeneration commit. The committed src-gen is already pure LF in the index (git ls-files --eol shows zero CRLF), so nothing needs rewriting; pending upstream codegen drift (Xtext 2.43 Activator/manifest changes) lands whenever a grammar is next regenerated for a real reason.
  • LfNormalizingFileSystemAccess stays. Its retirement is a runtime-output question independent of these settings and is folded into the upcoming check.core Xtend→Java migration, where the generator templates become deterministic anyway.

🤖 Generated with Claude Code

All seven workflows requested "\r\n" while the repository stores and
checks out LF everywhere (.gitattributes, line-endings CI check), so every
regeneration wrote files that disagreed byte-wise with the checkout. Flip the
lineDelimiter settings and the line.separator preference that
ddk-configuration links into the other projects' .settings.

Also set preferXtendStubs = false for the FormatterTestLanguage workflow: its
stub classes exist as handwritten .java files, and with the default the
generator's exact-path existence check misses them and resurrects .xtend
duplicates that were deliberately removed in 2024.

No regeneration is included: the committed src-gen is already pure LF in the
index, so this only changes what future regenerations emit. Refs dsldevkit#1345.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@joaodinissf joaodinissf marked this pull request as ready for review June 12, 2026 20:35
@joaodinissf joaodinissf requested a review from rubenporras June 12, 2026 20:35
@joaodinissf joaodinissf enabled auto-merge (rebase) June 12, 2026 20:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant