Commit graph

2879 commits

Author SHA1 Message Date
yzwduck
d24ca66dbb
Avoid modifying jumplist until jumping to ref (#2670)
When a goto command is cancelled, the jumplist should remain unchanged.

This commit delays saving the current selection to the jumplist until
jumping to a reference.
2022-06-05 19:44:55 +09:00
gavynriebau
026241cf72
Fix panic on close last buffer (#2367) (#2658)
* Fix panic on close last buffer (#2367)

In certain circumstances it was possible to cause a panic when closing
buffers due to some mishandling of view document history.

A change has been made to delete removed documents from the history of
accessed documents for each view. The ensures we don't attempt to jump
to a deleted document by mistake.

* Move remove document code into View function 'remove_document'

* Replace 'view.jumps.remove' call with 'view.remove_document' call
2022-06-05 11:27:41 +09:00
nosa
5b4e0a304b
Update selection style of Night Owl (#2668) 2022-06-04 10:40:39 +05:30
nosa
dfd0754394
Update keymap docs for window swapping (#2659) 2022-06-03 07:09:35 -05:00
Michael Davis
fd4858c03d
add tree-sitter-jsdoc (#2650) 2022-06-03 10:26:47 +05:30
Michael Davis
42d780b103
add tree-sitter-edoc (#2640)
* add tree-sitter-edoc

* fix escape character capture in markdown queries

* add field negation operator "!" to tsq highlights
2022-06-03 07:41:17 +08:00
Kirawi
4f3d0a7706
append set_line_ending to document history (#2649) 2022-06-02 10:46:53 -05:00
Frojdholm
f7c27b604f
Ignore SendErrors when handling grammars (#2641)
When handling grammars, fetching and building is done in a thread
pool.  Results are communicated over channels and the receiving
channel is closed on first error. This causes subsequent sends to
fail causing a mess in stderr. This ignores all SendErrors causing
only the first error to be printed.
2022-06-02 16:54:11 +09:00
Blaž Hrastnik
378f438fb0
fix: lsp: be more defensive about URI conversions 2022-06-02 14:07:19 +09:00
Blaž Hrastnik
6de6a3edbb
fix: lsp: be more defensive about URI conversions 2022-06-02 14:07:19 +09:00
Blaž Hrastnik
3d91c99c3e
fix: lsp: Sort edits by start range, Omnisharp sends them in reverse 2022-06-02 14:07:19 +09:00
Michael Zeller
99e08f50bd
catpuccin ui.popup should be a different color from ui.background (#2644) 2022-06-01 16:11:58 -05:00
Fanda Vacek
8d4c954060
CPON parser supports unsigned int (#2643)
Co-authored-by: Fanda Vacek <fvacek@elektroline.cz>
2022-06-01 15:11:14 -05:00
Ryan Russell
ae12c58f0f
Improve Readability (#2639) 2022-06-01 12:01:37 -05:00
Ben Lee-Cohen
fc666db6b9
Solarized Light: Fixing menu colors and adding English translation (#2626) 2022-05-31 10:15:32 -05:00
Andrey Tkachenko
fa2eeccc57
Fix unwrap error when undo after shell_append_output (#2625) 2022-05-31 23:08:16 +09:00
Clay
fc8c488322
Elixir: inject Markdown into docs, remove h sigil HEEx injection (#2619)
Co-authored-by: Michael Davis <mcarsondavis@gmail.com>
2022-05-30 21:32:14 -05:00
Timothy DeHerrera
eba82250bb
feat(lang): Update Nix grammar & improve queries (#2472) 2022-05-30 13:47:18 -05:00
Blaž Hrastnik
370a16d0f0
Update to ropey 1.5 2022-05-30 12:29:07 +09:00
Blaž Hrastnik
5ed6223990
fix: Remove empty scratch buffer from jumplists when removing it
Fixes #1238
2022-05-30 01:22:17 +09:00
Paul Graydon
710c4a84b2
Adjust colors in tokyonight themes (#2606) 2022-05-29 10:56:10 -05:00
Michael Zeller
b43074dad3
illumos linker doesn't currently have -z relro (#2602) 2022-05-29 10:52:48 -05:00
Marcin Puc
cd4622db9b
Update from-source install instruction in README (#2603) 2022-05-29 10:52:26 -05:00
Hugo
89c6e8aa94
Remove unnecessary unwrap (#2599)
`strip_prefix` will itself check whether the string starts with the
prefix, so the extra call to `starts_with` was unnecessary.
2022-05-29 11:13:21 +09:00
Blaž Hrastnik
10415a8069
Bump dependencies, allow retain_mut for now 2022-05-29 11:10:49 +09:00
Michael Davis
93e6eac15a
mention the C++ compiler in the grammar build failure message (#2597)
Earlier in the builder we enable C++ (`.cpp(true)`) but only mention
the C compiler in the build failure message. Some grammars that have
C++ external scanners can provoke build failures in this step if a
C++ compiler isn't installed, so mentioning it in the error message
should help out debugging.
2022-05-29 11:06:31 +09:00
pancake
7706a4a0d8
Add Vlang tree-sitter in the languages.toml (#2526)
Co-authored-by: pancake <pancake@nopcode.org>
Co-authored-by: Michael Davis <mcarsondavis@gmail.com>
2022-05-28 14:46:10 -05:00
booklearner
7c107d0d3a
Fix link to pop-dark in CHANGELOG.md (#2594) 2022-05-28 13:11:31 -05:00
Blaž Hrastnik
27609f5065
Fix the VERSION file 2022-05-29 01:07:30 +09:00
nitish-17
b31788102e
mention the requirement of C++ compiler for building grammar in doc (#2592) 2022-05-28 11:02:47 -05:00
Blaž Hrastnik
a106341fd7
Fix release action 2022-05-28 23:23:08 +09:00
Michael Davis
46f9320709
add 22.05 changelog notes (#2584) 2022-05-28 09:18:15 -05:00
Michael Davis
efae76160d
add section on syntax tree motions to the usage docs (#2568) 2022-05-26 10:39:58 +09:00
Ben Lee-Cohen
7160e745f7 Changing Macro color to avoid color confusion
I noticed that in Rust, `println!`being a macro, it matched the color of string literals. This was visually confusing to me, so I checked what the nvim catpuccin theme (https://github.com/catppuccin/nvim) does. While it is pretty different, it does use different colors for strings and all function types: https://share.cleanshot.com/RLG2y1

I don't know if blue or red makes more sense given the other syntax choices, but wanted to propose this change cc @IsotoxalDev
2022-05-25 09:54:20 -05:00
Michael Davis
82da9bd4f2 update Erlang grammar and queries
The update to the grammar itself covers the case where the document
is a single expression without a trailing newline such as "min(A, B)".
A small change to the parser now parses these expressions correctly
which improves the display of the function head in the signature
help popup.

The update to the queries marks 'andalso', 'orelse', 'not', etc. as
`@keyword.operator` which improves the look - it looks odd to see
operators that are words highlighted the same as tokens like '->'
or '=:='.
2022-05-25 21:26:26 +09:00
Michael Davis
45dd54082e update Gleam grammar and queries
With respect to the queries:

The locals scope for functions was not large enough, so a function's
parameter could outlive the function body. To fix it, we just widen
the scope to the `function` node.

See also https://github.com/gleam-lang/tree-sitter-gleam/issues/25

With respect to the parser:

An external scanner has been added that fixes the parsing of strings.
Previously, a comment inside a string would act like a comment rather
than string contents.

See also https://github.com/gleam-lang/tree-sitter-gleam/issues/14#issuecomment-1129263640

A new constructor node has been added as well which makes type
highlighting more fine grained.

See also https://github.com/gleam-lang/tree-sitter-gleam/pull/29
2022-05-25 21:26:26 +09:00
Andrey Tkachenko
10463fe32c Add parameter.around text object query 2022-05-25 21:26:06 +09:00
dependabot[bot]
da29527258 build(deps): bump once_cell from 1.10.0 to 1.12.0
Bumps [once_cell](https://github.com/matklad/once_cell) from 1.10.0 to 1.12.0.
- [Release notes](https://github.com/matklad/once_cell/releases)
- [Changelog](https://github.com/matklad/once_cell/blob/master/CHANGELOG.md)
- [Commits](https://github.com/matklad/once_cell/compare/v1.10.0...v1.12.0)

---
updated-dependencies:
- dependency-name: once_cell
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-05-25 21:25:47 +09:00
dependabot[bot]
a13ff27023 build(deps): bump regex from 1.5.5 to 1.5.6
Bumps [regex](https://github.com/rust-lang/regex) from 1.5.5 to 1.5.6.
- [Release notes](https://github.com/rust-lang/regex/releases)
- [Changelog](https://github.com/rust-lang/regex/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rust-lang/regex/compare/1.5.5...1.5.6)

---
updated-dependencies:
- dependency-name: regex
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-05-25 21:25:34 +09:00
Andrey Tkachenko
67fe16008e
Basic verilog support (#2552) 2022-05-24 12:52:32 -05:00
Erasin
386dccc84e
Add lua lsp (#2560) 2022-05-24 10:03:53 -05:00
Isotoxal
c429ed660f
Add Catppuccin Theme (#2546)
Co-authored-by: Michael Davis <mcarsondavis@gmail.com>
2022-05-24 09:02:26 -05:00
Blaž Hrastnik
d6865cdca3
nix: bump dependencies 2022-05-24 09:37:17 +09:00
Michael Davis
89c0998aee lower MSRV to 1.57.0
This line uses the Display trait for io::ErrorKind which was
stabilized in Rust 1.60.0. We can set MSRV all the way back to
1.57.0 by replacing it with a pretty-print.

Closes #2460.
2022-05-24 01:05:19 +09:00
Michael Davis
92df5a5425 check MSRV in CI
It's very easy to use new rust features without realizing it since
the CI and local development workflows may use the latest rust version.
We try to keep some backwards compatibility with rust versions to make
packaging easier for some OS-level package-managers like Void Linux's.
See #1881.

This change runs the "Check" step for the pinned version of rust in
the rust-toolchain.toml file as well as the MSRV version in a matrix.
In order to bump the MSRV, we need to edit

    .github/workflows/msrv-rust-toolchain.toml

This commit sets the MSRV as 1.60.0 but a later child commit will
reduce the MSRV back to 1.57.0.

Closes #2482.
2022-05-24 01:05:19 +09:00
Michael Davis
aa87adf54b pin the rust toolchain to 1.61.0
1.61.0 in particular introduced new clippy lints that unexpectedly
failed CI until addressed. The lints are a bit tough to fix since
the toolchain action starts using new rust versions almost immediately
after release, so if you aren't using rustup, you may have a hard
time reproducing the lint results until your package manager updates
rust.

This brings an extra burden that we have to remember to make a
commit/PR to update rust in CI.
2022-05-24 01:05:19 +09:00
Michael Davis
f6531c9db0 inherit rust toolchain channel from rust-toolchain.toml
We've forked actions-rs/toolchain and merged
https://github.com/actions-rs/toolchain/pull/209
so we can take advantage of full support of `rust-toolchain.toml`.
Without that PR, the action fails because the `rustup` version
built into the runners by default is too old. #2528 covers switching
back to the upstream when it includes those changes.
2022-05-24 01:05:19 +09:00
Blaž Hrastnik
35303f749e
Replace handwritten CI cache with Swatinem/rust-cache
The cache kept growing as dependencies kept changing and updating.
2022-05-23 13:48:00 +09:00
Jens Getreu
6801b28da0
Highlight active window in Autumn theme (#2531)
Co-authored-by: Jens Getreu <jens.getreu@dlh.lu>
2022-05-22 10:40:27 -05:00
Joel
682bcc3a32 fix: missing quotes around variable.other.member 2022-05-22 18:36:51 +09:00