[Repo Assist] Fix #803: do not copy _menu_template.html and _menu-item_template.html to output#995
Draft
github-actions[bot] wants to merge 1 commit intomainfrom
Conversation
…l to output These internal navigation template files were being copied to the output directory because the filter in prepFile/processFile only excluded files starting with "_template", but not the menu template variants. Added an additional guard to skip files whose name starts with "_menu" and ends with "_template.html" — covering both _menu_template.html and _menu-item_template.html (and any future _menu-*_template.html files). Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Contributor
Author
|
✅ Pull request created: #995 |
23 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
🤖 This is an automated pull request from Repo Assist.
Closes #803
Summary
When a project uses custom menu templates (
_menu_template.htmland/or_menu-item_template.html), these files were being incorrectly copied to the output directory as if they were regular content files.Root Cause
In
BuildCommand.fs, bothprepFileandprocessFilefilter out internal template files using:This correctly excludes
_template.html,_template.tex, etc. — but_menu_template.htmland_menu-item_template.htmlstart with_menu, not_template, so they slipped through and were copied to output.Fix
Added an additional guard in both
prepFileandprocessFile:This pattern covers the two known cases (
_menu_template.html,_menu-item_template.html) and any future_menu-*_template.htmlvariants, with minimal risk of false positives.Test Status