Skip to content

[bugfix] Anchor .moderne ignore pattern so it applies at any depth - #6685

Open
duncdrum wants to merge 1 commit into
eXist-db:developfrom
duncdrum:dp-fix-moderne-gitignore
Open

[bugfix] Anchor .moderne ignore pattern so it applies at any depth#6685
duncdrum wants to merge 1 commit into
eXist-db:developfrom
duncdrum:dp-fix-moderne-gitignore

Conversation

@duncdrum

@duncdrum duncdrum commented Sep 8, 2026

Copy link
Copy Markdown
Contributor

Summary

  • .moderne/* (slash in the middle) is anchored to the repo root by gitignore's rules, so it only ignored the top-level .moderne/ directory. Nested .moderne/ directories created when running Moderne recipes scoped to a submodule (e.g. exist-core/.moderne/) were left untracked, showing up as a dirty checkout.
  • Switches the pattern to **/.moderne/* so it applies at any depth, and anchors the context//moderne.yml negations to the repo root (!/.moderne/context/, !/.moderne/moderne.yml) so nested .moderne dirs elsewhere stay fully ignored while the root's committed context files remain tracked.

What Changed

  • .gitignore: .moderne/***/.moderne/*, negations anchored with a leading /.

Closes #6590

Test Plan

  • git check-ignore -v exist-core/.moderne/apply → now ignored
  • git check-ignore -v .moderne/context/architecture.md → still tracked (not ignored)
  • git status no longer reports nested .moderne working directories as dirty

`.moderne/*` has a slash in the middle, which anchors it to the repo
root, so it only ignored the top-level .moderne/ directory. Nested
.moderne/ directories created by running Moderne recipes scoped to a
submodule (e.g. exist-core/.moderne/) were left untracked, showing up
as a dirty checkout.

Switch to `**/.moderne/*` so the ignore applies at any depth, and
anchor the context/moderne.yml negations to the repo root so nested
.moderne directories stay fully ignored.

Closes eXist-db#6590
@duncdrum
duncdrum requested a review from a team as a code owner September 8, 2026 15:15
@github-actions

github-actions Bot commented Sep 8, 2026

Copy link
Copy Markdown
Contributor

📊 XQTS result comparison

Comparison of this run against develop.

Warning

20 test cases were recorded in only one of the two runs (0 only in the previous run, 20 only in the current run). The runner's JUnit output is not fully deterministic (see eXist-db/exist-xqts-runner#74), so totals and per-category deltas include recording noise; the newly passing/failing lists count only tests recorded in both runs.

Metric develop this run Change
🟢 Passed 28,828 (90.67%) 28,845 (90.66%) +17 (-0.00 pp)
🔴 Failures 1,566 1,569 +3
➖ Errors 134 134 0
➖ Skipped 1,267 1,267 0
🧪 Total tests 31,795 31,815 +20

Relative to develop: 0 newly passing, 2 newly failing, 0 new errors, 0 newly skipped — counting only tests recorded in both runs whose outcome changed.

🔴 Newly failing tests (2)
  • Constr-inscope-2 (was passing)
  • Constr-inscope-3 (was passing)
⚪ Recorded only in this run (20)
  • raytracer (failing)
  • sgml-queries-results-q3 (passing)
  • functx-fn-nilled-all (passing)
  • functx-fn-replace-5 (passing)
  • functx-fn-normalize-space-9 (passing)
  • functx-fn-string-2 (passing)
  • functx-fn-not-5 (passing)
  • functx-fn-normalize-space-1 (passing)
  • functx-fn-starts-with-8 (passing)
  • functx-fn-number-all (passing)
  • functx-fn-replace-18 (passing)
  • K2-DirectConOther-51 (passing)
  • fo-test-fn-max-003 (passing)
  • fo-test-fn-min-004 (passing)
  • fo-test-fn-tail-003 (passing)
  • fo-test-fn-remove-004 (passing)
  • fo-test-map-find-001 (passing)
  • fo-test-fn-deep-equal-003 (passing)
  • fo-test-fn-count-004 (passing)
  • fo-test-fn-fold-left-005 (passing)

Runtime: 341.8s (+70.45s vs develop).

@duncdrum
duncdrum requested a review from a team September 9, 2026 14:25
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.

[BUG] dirty checkout since a87c9d4

2 participants