Commit graph

636 commits

Author SHA1 Message Date
Álan Crístoffer
2c5288dafb
Replace MATLAB grammar (#7388) 2023-06-23 00:19:40 +02:00
Alexander Brevig
b4fe31cad6
Add forth-lsp and update tree-sitter-forth (#7334)
* feat: add forth lsp and update tree sitter

* fix: update highlights
2023-06-16 23:12:29 +02:00
spectre256
d8b7232a47
Add yank_joined command (#7195)
Resolves issue #6888 by adding a command to join all selections and yank
them to the specified register. The typed command takes an argument as
the separator to use when joining the selections.
2023-06-16 21:13:23 +02:00
Alex
3fb9fafb2a
Add config for default line ending (#5621) 2023-06-16 12:02:15 -05:00
Ivan Svoboda
df094909d1
Webc language support (#7290)
* feat: add webc language support

* feat: add to lang-support book webc
2023-06-13 17:41:30 +02:00
Thomas Aarholt
cbe2308210
Explain how to enter Select mode in keymap (#7333)
* Explain how to enter Select mode

Also added an equivalent explanation that Insert mode is the default, with how to return to it.

* Fix glarious typo
2023-06-13 17:07:12 +02:00
Zisulin Morbrot
fbd22afe29
Add rl and rla aliasses for reload and reload-all commands (#7158) 2023-06-13 08:50:50 -05:00
kazimir malevich
37fcd160db
Clarify the runtime directory location in installation docs (#6624)
* runtime config made clearer

* following Unix FHS

* we probably want to install Helix as a regular user without sudo access

* suggestions adopted from @the-mikedavis

* attempted to synthesise comments given

* capitalisation of second header

* required changes hopefully made

* we should have a match now

* Linux windows dir match
2023-06-13 03:35:12 +02:00
Selwyn
18e07addfd
Use Vue language server based on Volar (#7312) 2023-06-12 00:46:47 +09:00
Luca Schlecker
dbd248fdfa add config option for instant completion entry preview (defaulting to true).
Signed-off-by: Luca Schlecker <luca.schlecker@hotmail.com>
2023-06-09 13:23:29 -04:00
spectre256
00b152facd
Add register statusline element (#7222) 2023-06-08 14:34:07 -05:00
Tshepang Mbambo
e2a1678436
Fix book configuration for edit template (#7278) 2023-06-08 17:12:36 +09:00
Tshepang Mbambo
27891cdc8d
misc doc fixes/improvements (#7282) 2023-06-08 13:27:58 +09:00
Christoph Sax
d324feb072
Add support for language t32 (#7140)
Co-authored-by: Christoph Sax <christoph.sax@mailbox.org>
2023-06-07 18:01:25 -05:00
Tshepang Mbambo
2f9b63999f
Break long sentence in book configuration footnote (#7279) 2023-06-07 23:19:55 +02:00
Alexander Brevig
78e8695420
Add support for Forth (#7256) 2023-06-06 08:14:34 -05:00
Ivan Tkachuk
2022e6175b
Add blueprint language (#7213)
* Add blueprint tree-sitter support

* Add blueprint lsp support

* Run cargo xtask docgen
2023-06-05 10:40:14 +02:00
Rich Seymour
751da01303
Update install.md instructions regarding symlinks (#7231)
* Update install.md

Fixes `ln` command line bug that could hit users moving from packaged to source builds.

* Remove extra 'how to' command example
2023-06-05 02:06:25 +02:00
avaunit02
232d9f96a0
Fix textobject keybindings in usage docs (#7197) 2023-06-04 17:20:54 +02:00
Zisulin Morbrot
d511122279
Add description for 'ui.text.focus' in theme docs (#7177) 2023-05-31 06:57:17 +08:00
Martin Weinelt
61a89956e3
book: Mention Helix package in nixpkgs (#7064) 2023-05-26 04:33:20 -05:00
Blaž Hrastnik
0266ec6ba3
Update language support doc 2023-05-26 13:43:41 +09:00
LeoniePhiline
41f52d74fe
fix(docs): Remove config from language configuration docs (#7082) 2023-05-19 19:27:21 -05:00
Szabin
70e4cdbd8e
Add command to merge non-consecutive ranges (#7053)
* Add command for merging non-consecutive ranges

* Add `merge_selections` command to book

* Simplify `merge_ranges`

Heeded the advice of @the-mikedavis to stop iterating over all ranges and simply merge the first and the last range, as the invariants of `Selection` guarantee that the list of ranges is always sorted and never empty.

* Clarify doc comment of `merge_ranges`
2023-05-20 01:31:39 +02:00
Philipp Mildenberger
f8fa0d8a10 Clarify language-servers documentation for mergeable LSP features (diagnostics, code-action, completion, document-symbols and workspace-symbols) 2023-05-18 22:11:38 +02:00
Philipp Mildenberger
7d20740b5b Fix docgen and lsp-stop documentation 2023-05-18 21:48:32 +02:00
Philipp Mildenberger
d963050621 Format/fix language docs a bit 2023-05-18 21:48:32 +02:00
Philipp Mildenberger
74e21e1b25 Fix some lints/docgen hints 2023-05-18 21:48:32 +02:00
Philipp Mildenberger
71551d395b Adds support for multiple language servers per language.
Language Servers are now configured in a separate table in `languages.toml`:

```toml
[langauge-server.mylang-lsp]
command = "mylang-lsp"
args = ["--stdio"]
config = { provideFormatter = true }

[language-server.efm-lsp-prettier]
command = "efm-langserver"

[language-server.efm-lsp-prettier.config]
documentFormatting = true
languages = { typescript = [ { formatCommand ="prettier --stdin-filepath ${INPUT}", formatStdin = true } ] }
```

The language server for a language is configured like this (`typescript-language-server` is configured by default):

```toml
[[language]]
name = "typescript"
language-servers = [ { name = "efm-lsp-prettier", only-features = [ "format" ] }, "typescript-language-server" ]
```

or equivalent:

```toml
[[language]]
name = "typescript"
language-servers = [ { name = "typescript-language-server", except-features = [ "format" ] }, "efm-lsp-prettier" ]
```

Each requested LSP feature is priorized in the order of the `language-servers` array.
For example the first `goto-definition` supported language server (in this case `typescript-language-server`) will be taken for the relevant LSP request (command `goto_definition`).

If no `except-features` or `only-features` is given all features for the language server are enabled, as long as the language server supports these. If it doesn't the next language server which supports the feature is tried.

The list of supported features are:

- `format`
- `goto-definition`
- `goto-declaration`
- `goto-type-definition`
- `goto-reference`
- `goto-implementation`
- `signature-help`
- `hover`
- `document-highlight`
- `completion`
- `code-action`
- `workspace-command`
- `document-symbols`
- `workspace-symbols`
- `diagnostics`
- `rename-symbol`
- `inlay-hints`

Another side-effect/difference that comes with this PR, is that only one language server instance is started if different languages use the same language server.
2023-05-18 21:48:30 +02:00
Kitsu
92c328c088
Add wbc and wbc! commands (#6947) 2023-05-09 22:21:29 +02:00
Ollie Charles
8424f387b5
Remove tree-sitter-cabal (#6996) 2023-05-09 21:31:22 +02:00
David Else
69332ae3b2
Add Flathub as third party repository (#6994) 2023-05-09 15:38:36 +02:00
Dave Powers
5ae30f1993
Fix keymap select / extend mode anchor link (#6974) 2023-05-05 09:43:56 -05:00
taupiqueur
c49faf5681
Add language server command for Crystal (#6948) 2023-05-03 09:43:37 +09:00
sscheele
f52e81b1f3
Update docs for move_visual_line_* (#6918) 2023-04-30 14:26:18 -05:00
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
2023-04-28 18:21:34 +09:00
jorge
204d1eba4b
feat(commands): add clear-register typable command (#5695)
Co-authored-by: Jorge <chorcheus@tutanota.com>
2023-04-27 21:57:05 +02:00
ap29600
9cdc6b2e8a
Change Odin grammar to ap29600/tree-sitter-odin (#6766)
* Change Odin grammar to `ap29600/tree-sitter-odin`

The previously adopted grammar, `MineBill/tree-sitter-odin`, is unmaintained and mentions my repository as an alternative source.

* update queries

* docgen

* fix queries

* Update runtime/queries/odin/highlights.scm

Co-authored-by: Michael Davis <mcarsondavis@gmail.com>

* remove `ERROR` query for `odin`

* track the latest rev in `ap29600/tree-sitter-odin`

* runtime/queries/odin/highlights.scm: update rune highlight class

Co-authored-by: Michael Davis <mcarsondavis@gmail.com>

---------

Co-authored-by: Michael Davis <mcarsondavis@gmail.com>
2023-04-27 16:32:21 +02:00
Vitalii Solodilov
2836ea2ac4
feat: add a config option to exclude declaration from LSP references (#6886)
* feat: added the config option to exclude declaration from reference query

Fixes: #5344

* fix: review

* fix: review
2023-04-27 16:30:15 +02:00
Wesley
903bdaae87
Set PerlNavigator as the language server for Perl (#6860) 2023-04-27 01:28:54 +02:00
Atticus Sebastiani
228a4af35f
make :u alias :update (#6835)
* Gave the command update the alias u

* Re added trailing newline

* generated docs
2023-04-23 04:07:34 +02:00
Michael T. Mordowanec
a1044a6c68
Change soft-wrap.wrap_at_text_width to kebab case in documentation (#6842)
Solves #6803.
2023-04-21 16:45:50 -05:00
David Else
83c307a66a
Improve and update the installation documentation (#6809) 2023-04-20 00:56:18 +02:00
VuiMuich
4cdba7cccd
Add standalone language support for just (#6453)
Co-authored-by: Michael Davis <mcarsondavis@gmail.com>
2023-04-14 17:03:21 +02:00
Michael
161fef2166
Add DTD language support (#6644)
- Added syntax highlighting for the DTD subset of the XML spec.
- Included .dtd and .ent as common file extensions
2023-04-12 15:28:51 -05:00
lefp
fff8543b58
Add OpenCL tree-sitter and LSP config (#6473) 2023-04-12 14:42:41 -05:00
Matouš Dzivjak
70de5026b8
feat(languages): Support markdoc (#6432)
Add basic support for [markdoc](https://markdoc.dev/).

For language server, see: https://github.com/markdoc-extra/markdoc-ls
For tree sitter, see: https://github.com/markdoc-extra/tree-sitter-markdoc
2023-04-12 10:28:03 -05:00
Ollie Charles
92c5f5f18c
Initial Cabal language support (#6485) 2023-04-12 08:38:11 -05:00
tippfehlr
5106a124ed
Fix file-picker.follow-symlinks config option name in docs (#6685) 2023-04-10 10:09:45 -05:00
Nico Bos
894c2b9edb
Add Windows install instructions using Winget (#6602) 2023-04-09 14:57:41 -05:00