Commit Graph

4951 Commits

Author SHA1 Message Date
dependabot[bot]
d62fb8c8d7
build(deps): bump chrono from 0.4.24 to 0.4.25 (#7171)
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-05-30 09:51:13 +09:00
dependabot[bot]
a367a713ef
build(deps): bump cachix/install-nix-action from 20 to 21 (#7170)
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-05-30 09:49:45 +09:00
Ethan Wilkes
3334e7e4b2
fixed repeat_last_motion extends selection (#7159) 2023-05-29 00:51:22 +09:00
yvt
3a8592abdb
feat(languages): recognise .gir as XML (#7152) 2023-05-27 09:01:50 -05:00
Jimmy Zelinskie
b107814e39
languages: add .zimrc to bash filetypes (#7146) 2023-05-27 00:55:25 +02:00
Gammut
86ef389c0d
Highlight query improvements for java and typescript (#7145)
* Add missing queries to java highlights

* Fix generic type bracket highlights in typescript
2023-05-26 23:37:19 +02:00
Martin Weinelt
61a89956e3
book: Mention Helix package in nixpkgs (#7064) 2023-05-26 04:33:20 -05:00
Ravi Shekhar Jethani
6e647e83ed
Update spacebones_light.toml (#7125)
Better contrast between type variable and its members
2023-05-26 10:47:03 +02:00
Casper Rogild Storm
1dd1735909
Correct selection color (#7138) 2023-05-26 10:46:07 +02:00
Ikko Eltociear Ashimine
349e2b5f0e
Fix typo in syntax.rs (#7114)
seperator -> separator
2023-05-26 10:45:15 +02:00
William Etheredge
a2e11af608
Support hidden justfiles (#7088) 2023-05-26 10:43:48 +02:00
Brandon Sprague
16375cd94a
Treat 'Vagrantfile' files as Ruby code (#7112)
`Vagrantfile`s are configuration files for the [vagrant](https://www.vagrantup.com/) tool, and they are written in Ruby. Even as vagrant [is ported to Go](https://www.hashicorp.com/blog/toward-vagrant-3-0), `Vagrantfile`s [will be written in Ruby](https://developer.hashicorp.com/vagrant/docs/experimental/vagrant_go)

When a Vangrantfile is created, it starts with these lines:

```
```

But since Helix (quite reasonably) doesn't change editor behavior based on file contents, adding this to `languages.toml` seems like a reasonable way to get this functionality.
2023-05-26 10:43:15 +02:00
Viktor Kleen
0c21c227e1
Update languages.toml for Nickel (#7059) 2023-05-26 02:23:15 -05:00
Blaž Hrastnik
0266ec6ba3
Update language support doc 2023-05-26 13:43:41 +09:00
Blaž Hrastnik
591629ec11
fix compilation 2023-05-26 13:35:03 +09:00
Blaž Hrastnik
c6d1430243
Drop old cairo grammar, alias to rust for now 2023-05-26 11:17:30 +09:00
Matthew Toohey
207829eefe
Fix off-by-one in select symbol references (#7132) 2023-05-25 14:01:56 +02:00
Poliorcetics
8e2660b5cc
Update diagnostics correctly on LSP exit (#7111)
* chore: avoid format! call with argument when useless

* feat: also clear diagnostics for unopened documents when exiting an LSP

* feat: we already worked on `self.editor.diagnostics` no need to redo the checks
2023-05-23 12:33:01 +02:00
dependabot[bot]
6043c3c3db
build(deps): bump bitflags from 2.2.1 to 2.3.1 (#7117)
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-05-23 14:19:50 +09:00
dependabot[bot]
a66e287654
build(deps): bump toml from 0.7.3 to 0.7.4 (#7120)
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-05-23 14:19:07 +09:00
dependabot[bot]
16275db817
build(deps): bump regex from 1.8.1 to 1.8.2 (#7119)
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-05-23 14:18:51 +09:00
dependabot[bot]
d765132426
build(deps): bump pulldown-cmark from 0.9.2 to 0.9.3 (#7118)
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-05-23 14:18:38 +09:00
yvt
16e0340b4a feat(languages): recognise Cargo.lock as TOML 2023-05-21 22:51:33 -04:00
Chris
d3cca0f357
Recognise XAML files as XML (#7083) 2023-05-20 02:38:55 +02: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
Charles Hall
e4a9bec562
fix off-by-one git-commit rulers (#7072)
Characters should maximally reside *inside* the ruler, not on top of it.
2023-05-20 01:29:06 +02:00
Yt
ff442eecd0
nix: add overlay for convenient package usage (#7078) 2023-05-19 22:21:05 +09:00
Blaž Hrastnik
53f47bc477
Merge pull request #2507 from Philipp-M/multiple-language-servers
Add support for multiple language servers per language
2023-05-19 09:39:35 +09:00
Philipp Mildenberger
2a512f7c48 Rebase cleanup/fixes and use lsp::CompletionItem in item_to_transaction directly 2023-05-18 22:25:32 +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
b6d0e26814 Sort language servers table in languages.toml and rename language server 'R' to 'r' 2023-05-18 22:11:37 +02:00
Philipp Mildenberger
f45bbf165e Apply all review suggestions (doc_id -> id, error message, unnecessary if)
Co-authored-by: Pascal Kuthe <pascal.kuthe@semimod.de>
2023-05-18 22:04:49 +02:00
Philipp Mildenberger
656ee24966 Simplify gutter diagnostics rendering by using partition_point instead of binary search
Co-authored-by: Pascal Kuthe <pascal.kuthe@semimod.de>
2023-05-18 22:04:49 +02:00
Philipp Mildenberger
2b746ea6fa Some minor clarity/cosmetic improvements
Co-authored-by: Pascal Kuthe <pascal.kuthe@semimod.de>
2023-05-18 22:04:49 +02:00
Philipp Mildenberger
39b9a4bba2 Add function Editor::language_server_by_id and refactor/simplify related code, also don't 'crash' in completion menu if language_server somehow disappeared 2023-05-18 22:04:47 +02:00
Philipp Mildenberger
521cdec5a1 Remove TODO comment in helix_lsp::Registry::restart and add doc-comment on top of function instead 2023-05-18 21:58:17 +02:00
Philipp Mildenberger
dcb07673f8 Reorder id generation for Clients to stay close to the old behavior 2023-05-18 21:58:17 +02:00
Philipp Mildenberger
56748509bd Reduce boilerplate by 'use lsp::*' in Client::supports_feature, and remove TODO comment 2023-05-18 21:58:17 +02:00
Philipp Mildenberger
3e4bac1d96 Fix lsp_restart across multiple different document scopes (language servers weren't restarted, if not of the same scope id), and fix some smaller rebase issues 2023-05-18 21:58:17 +02:00
Philipp Mildenberger
2a21b939c4 Fix crash with filtered diagnostics in gutter (e.g. when diagnostics aren't visible) 2023-05-18 21:58:17 +02:00
Philipp Mildenberger
93fd79a949 Remove offset_encoding in CodeActionOrCommandItem, as it can be retrieved on demand 2023-05-18 21:58:17 +02:00
Philipp Mildenberger
073000e54d Maintain language servers TOML array order in doc.language_servers 2023-05-18 21:58:17 +02:00
Philipp Mildenberger
ff26208427 Filter language servers also by capabilities in doc.language_servers_with_feature
* Add `helix_lsp::client::Client::supports_feature(&self, LanguageServerFeature)`
* Extend `doc.language_servers_with_feature` to use this method as filter as well
* Add macro `language_server_with_feature!` to reduce boilerplate for non-mergeable language server requests (like goto-definition)
* Refactored most of the `find_map` code to use the either the macro or filter directly via `doc.language_servers_with_feature`
2023-05-18 21:58:17 +02:00
Philipp Mildenberger
9d089c27c7 Fix docgen again 2023-05-18 21:58:17 +02:00
Philipp Mildenberger
451fe528bb Filter out already seen language servers in requests that can be sent to multiple language servers (code-action, completion, symbol pickers) 2023-05-18 21:58:17 +02:00
Philipp Mildenberger
8ee599942a Optimize gutter diagnostics and simplify shown_diagnostics 2023-05-18 21:58:17 +02:00
Philipp Mildenberger
8ab6d7be5e Use let else instead of variable and fix some error messages
Co-authored-by: Pascal Kuthe <pascal.kuthe@semimod.de>
2023-05-18 21:58:17 +02:00
Philipp Mildenberger
1d5d5dab47 Remove offset_encoding in CompletionItem 2023-05-18 21:58:15 +02:00
Philipp Mildenberger
2eeac10755 Refactor doc language servers to a HashMap, and the config to use a Vec to retain order 2023-05-18 21:48:32 +02:00