You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
helix/book/src
Timothy DeHerrera 9c6c63a2be
inject language based on file extension & shebang (#3970)
* inject language based on file extension

Nodes can now be captured with "injection.filename". If this capture
contains a valid file extension known to Helix, then the content will
be highlighted as that language.

* inject language by shebang

Nodes can now be captured with "injection.shebang". If this capture
contains a valid shebang line known to Helix, then the content will
be highlighted as the language the shebang calls for.

* add documentation for language injection

* nix: fix highlights

The `@` is now highlighted properly on either side of the function arg.

Also, extending the phases with `buildPhase = prev.buildPhase + ''''`
is now highlighted properly.

Fix highlighting of `''$` style escapes (requires tree-sitter-nix bump)

Fix `inherit` highlighting.

* simplify injection_for_match

Split out injection pair logic into its own method to make the overall
flow easier to follow.

Also transform the top-level function into a method on a
HighlightConfiguration.

* markdown: add shebang injection query
2 years ago
..
generated feat(commands): add clear-register typable command (#5695) 2 years ago
guides inject language based on file extension & shebang (#3970) 2 years ago
SUMMARY.md inject language based on file extension & shebang (#3970) 2 years ago
commands.md Rewrite and refactor all documentation (#5534) 2 years ago
configuration.md feat: add a config option to exclude declaration from LSP references (#6886) 2 years ago
from-vim.md Fix minor grammar issue in 'from-vim' docs (#6667) 2 years ago
install.md Improve and update the installation documentation (#6809) 2 years ago
keymap.md Rewrite and refactor all documentation (#5534) 2 years ago
lang-support.md Rewrite and refactor all documentation (#5534) 2 years ago
languages.md Change soft-wrap.wrap_at_text_width to kebab case in documentation (#6842) 2 years ago
remapping.md Rewrite and refactor all documentation (#5534) 2 years ago
themes.md feat(debug): highlight current line (#5957) 2 years ago
title-page.md book: add wiki links to the title page and install page (#3017) 2 years ago
usage.md Rewrite and refactor all documentation (#5534) 2 years ago