E543 Add `.ftlh` extension to Freemarker by tajakobsen · Pull Request #7551 · github-linguist/linguist · GitHub
[go: up one dir, main page]

Skip to content

Conversation

tajakobsen
Copy link
Contributor
@tajakobsen tajakobsen commented Aug 29, 2025
  • Add .ftlh as an extension for Freemarker
  • Add samples for .ftlh

Description

Hi,

I propose adding the .ftlh extension for Freemarker as discussed in #7550 .

The alternative file extension indicate to the Freemarker-library if the output should be HTML-escaped. See https://freemarker.apache.org/docs/dgui_misc_autoescaping.html#:~:text=ftlh,extensions

Checklist:

 - Add `.ftlh` and `.ftlx` as extensions for Freemarker
 - Add samples for `.ftlh` and `.ftlx`
@tajakobsen tajakobsen requested a review from a team as a code owner August 29, 2025 12:03
Copy link
Member
@lildude lildude left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The sample files added in this PR reflects this:

* The `.ftlh` files are copies of the `.ftl` files, which will render HTML-documents.

Please don't do this. These are very old and terrible samples from before we started requiring real-world usage examples. Please find real examples for the new extensions and add those. Update the PR template to reflect the license and source of each file.

@tajakobsen
Copy link
Contributor Author

I replaced the example files with two new ones from real-world projects.

I also wanted to ensure that both "syntax flavors" are represented in the samples:

  1. blocks-card.ftlh uses the angle-bracket-syntax
  2. header.ftlh uses the square-bracket-syntax

@tajakobsen tajakobsen requested a review from lildude September 1, 2025 06:53
@tajakobsen tajakobsen requested a review from lildude September 9, 2025 12:54
@lildude lildude changed the title Add .ftlh and .ftlx extensions to Freemarker Add .ftlh extension to Freemarker Sep 9, 2025
Copy link
Member
@lildude lildude left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Thanks.

Important

The changes in this PR will not appear on GitHub until the next release has been made and deployed. See here for more details.

@lildude lildude enabled auto-merge September 9, 2025 13:24
@lildude lildude added this pull request to the merge queue Sep 9, 2025
Merged via the queue into github-linguist:main with commit f8e59e5 Sep 9, 2025
5 checks passed
@tajakobsen tajakobsen deleted the support-for-ftlh-and-ftlx branch September 9, 2025 14:04
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.

2 participants
0