Riley Bruins
f58cae6c22
feat: more @keyword.type captures
2024-05-01 09:59:50 +02:00
Amaan Qureshi
3af2d894d4
fix(go): update queries from upstream
...
also bump templ to match
2024-04-10 11:07:30 +02:00
Phạm Huy Hoàng
722617e672
refactor(format): drop extra indentation for field
2024-03-21 15:51:26 +01:00
再生花
31641d72a4
feat(format-scripts): linewrap predicates
...
"format-ignore".kick()
2024-02-23 10:42:01 +02: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
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
Yuki Ito
d92bfe2cbd
feat(go): add max and min to @function.builtin
2023-08-10 11:18:57 -04:00
ShellCode33
d9e75a1736
queries/*/highlights.scm : remove @spell for strings
2023-08-07 16:39:40 +01:00
Amaan Qureshi
6de5ceba03
fix(go): properly highlight chan/map ( #4875 )
2023-05-30 00:09:37 -04:00
Yuki Ito
ec97c5ec72
fear(go): add clear to @function.builtin
2023-05-26 09:51:51 -04:00
mohsen
f2778bd1a2
highlights(go): add some highlights
...
- added missing operators
- added iota constant
- added comparable type
- edited go keyword types
2023-05-21 20:04:40 +02:00
Amaan Qureshi
e2cf8977fd
feat(go): highlight constructors, remove _ as @constant
2023-05-02 07:52:45 -04:00
Amaan Qureshi
5a87bc98da
feat: add @comment.documentation where applicable
2023-03-05 17:15:32 -05:00
Stephan Seitz
e71dfc1e7a
highlights(go): add @label
2022-12-04 11:56:40 +01:00
Viorel Craescu
be5ed65f7f
add golang type definition highlight
2022-11-21 14:00:36 +01:00
Lewis Russell
37398c7d68
feat(spell): support more languages
2022-09-26 13:47:12 +01:00
Lewis Russell
2a63ea5665
feat(spell): upstream spell queries from spellsitter
2022-09-06 12:44:19 +01:00
lfenzo
2f9ae24ffa
Split func/method definition from calls in Go highlighting queries
2022-08-03 12:05:30 -07:00
Viorel Craescu
6f1bf2feec
add go1.18 any type
2022-07-10 14:53:27 +02:00
Viorel Craescu
2f340af135
remove type definition
2022-07-09 21:18:03 +02:00
Viorel Craescu
eb3f263bfe
add type def highlight, add field declaration highlight and remove constant highlight
2022-07-09 21:18:03 +02:00
Viorel Craescu
32e033a8f5
add method spec highlight and block folds ( #3151 )
2022-07-09 11:35:10 +00:00
Pieter van Loon
dcc5895e7c
Highlight named fields in struct literals
2022-07-08 00:13:46 +02:00
Stephan Seitz
542d098e14
highlights(go): highlight package_identifier as @namespace ( #2371 )
2022-01-28 18:44:32 +01:00
Stephan Seitz
ba2959347d
highlights(go): highlights "~"
...
Follow upstream change
beb36fc9be
2022-01-09 20:16:49 +01:00
Sergio Alejandro Vargas
820b4a9c21
Use @keyword.function consistently
2021-07-06 00:53:40 +02:00
antonk52
90f15d9bf7
feat(keywords) merge return and yield into keyword.return group
2021-07-04 21:49:17 +02:00
antonk52
bd9095e969
feat(keywords) add keyword.return & keyword.yield
2021-07-04 21:49:17 +02:00
Stephan Seitz
2e073285dc
highlights(go): modernize highlights.scm
2021-07-01 22:38:26 +02:00
Joakker
c699cc2e47
Use #any-of? instead of #match? where posible
2021-06-25 00:22:48 +02:00
Stephan Seitz
f8314a4df3
highlights(go): Highlight const_declaration
...
Fixes #1157
2021-04-07 13:03:44 +02:00
Yuki Ito
b818ace315
go: add builtin types
2021-03-19 13:48:24 +01:00
Yuki Ito
df81a91ba9
go: add builtin functions
2021-03-16 17:45:29 +01:00
rockerBOO
9279ff5065
go: Add package_identifier as variable
2020-12-10 23:56:01 +01:00
Thomas Vigouroux
b90e520ccd
ci: fix wrong queries
2020-09-11 12:02:35 +02:00
Steven Sojka
ce43dbf54c
fix(queries): use vim-match for non lua regexes
2020-08-16 18:31:56 +02:00
winwisely268
954b8c718f
fixes golang method highlights (overwritten by parameter in the ordering)
2020-07-22 11:28:57 +02:00
Stephan Seitz
04040c61c7
Add highlights.scm for Go
2020-06-07 12:39:58 +02:00