Skip to content

Add HCL/Terraform support via CodeMirror in fenced code block#6302

Merged
nathanlesage merged 4 commits into
Zettlr:developfrom
a-goodarzi:feat/codemirror-hcl-terraform-support
Apr 25, 2026
Merged

Add HCL/Terraform support via CodeMirror in fenced code block#6302
nathanlesage merged 4 commits into
Zettlr:developfrom
a-goodarzi:feat/codemirror-hcl-terraform-support

Conversation

@a-goodarzi

Copy link
Copy Markdown
Contributor

Description

This PR adds HCL/Terraform fenced code block support in the markdown parser and updates code block autocomplete to suggest both hcl and terraform.

Changes

  • Added CodeMirror HCL language mapping in markdown-parser.ts using Codemirror-lang-hcl and mapped both hcl and terraform selectors to the same HCL language
  • Added autocomplete entries for both HCL and Terraform code fences

Breaking API changes: none.

Additional information

Terraform syntax is based on HCL, so both fence names are highlighted through the same CodeMirror language support.

Tested on: Cachyos Rolling and macOS Tahoe (26.04.1)

@boring-cyborg

boring-cyborg Bot commented Apr 23, 2026

Copy link
Copy Markdown

Thank you for opening your first PR! 🎉 We would like to thank you already for your contribution. If everything checks out, we'll make sure to review the PR as soon as possible and give feedback. Please note a few things:

  • For every PR, the automated pipeline will run the linter and unit tests on
    your code. Should these fail, we will not merge your PR.
  • Activate your notifications and check your inbox regularly to respond to our
    reviews and/or comments.

We are glad for every improvement that makes its way into the app, so we look forward to collaborating on merging this PR.

@nathanlesage

Copy link
Copy Markdown
Member

Looks good, thank you!

@nathanlesage nathanlesage merged commit de5a342 into Zettlr:develop Apr 25, 2026
1 check failed
@boring-cyborg

boring-cyborg Bot commented Apr 25, 2026

Copy link
Copy Markdown

Your PR got merged! Welcome to the party! 🔥

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