Christian Clason
692b051b09
feat!: drop modules, general refactor and cleanup
2025-05-12 18:43:40 +02:00
gbprod
173515a5d2
feat(gitcommit): remove overflow rule
...
This commit remove the highlight of the overflow node in gitcommit syntax
introduced [by this PR](https://github.com/nvim-treesitter/nvim-treesitter/pull/6222 ).
This node will be removed when [this PR](https://github.com/gbprod/tree-sitter-gitcommit/pull/68 )
will be merge.
2024-06-27 09:21:30 +02:00
Riley Bruins
e5af2d7fdc
fix(gitcommit): correct the file path capture ( #6765 )
2024-06-14 14:07:43 +09:00
Riley Bruins
8e349b1ea9
feat(gitcommit): highlight overflow in commit body
2024-03-01 08:30:00 +01:00
Christian Clason
5cc5627487
fix(comments)!: consolidate note captures
...
Distinguishing `hint` and `info` is too confusing; it's enough to have
`error`, `warning`, `todo`, and `note`.
2024-01-20 17:52:50 +01:00
Pham Huy Hoang
57a8acf0c4
chore: query formatting
2024-01-19 16:58:37 +01:00
Christian Clason
1ae9b0e455
feat!: align standard captures with upstream
...
Problem: Sharing highlight queries with upstream tree-sitter and
Helix is difficult.
Solution: Where reasonable, use capture names in tree-sitter's standard
list or Helix's Atom-style hierarchy.
Specifically:
* tree-sitter "standard capture names"
(3f44b89685/highlight/src/lib.rs (L20-L72) ):
- `@parameter` -> `@variable.parameter`
- `@field` -> `@variable.member`
- `@namespace` -> `@module`
- `@float` -> `@number.float`
- `@symbol` -> `@string.special.symbol`
- `@string.regex` -> `@string.regexp`
- `@text.*` -> `@markup.*` (`strong`, `italic`, `link`, `strikethrough`; with exceptions; see below)
- `@text.title` -> `@markup.heading`
- `@text.literal` -> `@markup.raw`
- `@text.reference` -> `@markup.link`
- `@text.uri` -> `@markup.link.url` (in markup links)
- `@string.special` -> `@markup.link.label` (non-url links)
- `@punctuation.special` -> `@markup.list` (markdown lists only; move subitems from `@text.todo`)
* Helix captures
(https://docs.helix-editor.com/master/themes.html#syntax-highlighting ):
- `@method` -> `@function.method`
- `@method.call` -> `@function.method.call`
- `@text.{todo,warning,note,danger}` -> `@comment.{error,warning,hint,info,todo}`
- `@text.diff.{add,delete,}` -> `@diff.{plus,minus,delta}`
- `@text.uri` -> `@string.special.url` (outside markup)
- `@preproc` -> `@keyword.directive`
- `@define` -> `@keyword.directive`(`.define`?)
- `@storageclass` -> `@keyword.storage`
- `@conditional` -> `@keyword.conditional`
- `@debug` -> `@keyword.debug`
- `@exception` -> `@keyword.exception`
- `@include` -> `@keyword.import`
- `@repeat` -> `@keyword.repeat`
* cleanup
- remove some redundant `@conceal` (but still allow it for conceal-only patterns)
- remove obsolete `@error` (syntax linting is out of scope for this repo)
- sort, cleanup capture list in `CONTRIBUTING.md`
2024-01-19 16:58:37 +01:00
gbprod
bd55179893
feat(gitcommit): add highlight group for subject_prefix ( #5774 )
2023-12-09 12:36:17 +09:00
Pham Huy Hoang
107e61afb7
refactor: Remove all (ERROR) @error captures
...
As discussed in PR#5421, capturing `@error` is inconsistent, requiring
deep nesting (or priority) in order to correctly have red backgrounds to
it.
Some queries has this capture, some don't. For consistency purposes,
removing all of them is more preferable.
For re-enabling error, either add `(ERROR) @error` or `(ERROR _ @error)`
to your custom queries.
2023-10-25 18:18:50 +02:00
ObserverOfTime
5e055d81e0
feat(gitcommit): add spell checking
2022-11-25 09:00:42 +01:00
gbprod
118a87f7e7
feat: add gitcommit parser
2022-11-24 12:26:02 +01:00