Commit Graph

4389 Commits

Author SHA1 Message Date
w0rp
dd3abf1ad9
Close #4605 - Emulate InsertLeave mode
Use a repeating timer to emulate InsertLeave mode for users who have not
rebound <C-c> to <Esc>, like many experienced Vim users do. This allows
ALE to start linting when you finish typing by default without having
to know about this quirk in Vim or Neovim.
2023-09-08 18:42:45 +01:00
w0rp
bf55175b69
#4454 Clean up root test directory tests
Combine cases into smaller tests of tests and remove tests we no longer
need. Linter tests have been moved to where they should be.
2023-09-08 01:00:35 +01:00
w0rp
e5816964d1
Give up on Windows tests again for now
Add directories and files to AppVeyor to make it skip running if it
doesn't need to run.
2023-09-07 21:20:58 +01:00
w0rp
89428cb957
Try windows-2019, as windows-latest is slow as Hell 2023-09-07 21:06:44 +01:00
w0rp
0d07f4dba6
Try to fix building Vader again 2023-09-07 20:57:13 +01:00
w0rp
bf8e7f6368
Stop redirecting error streams for Vader build 2023-09-07 20:54:35 +01:00
w0rp
752acbe79b
Try http:// for downloading Vim 2023-09-07 20:52:42 +01:00
w0rp
9713faf192
Attempt running Windows rests relative to GitHub dir 2023-09-07 20:47:20 +01:00
w0rp
d52c3db238
Try to fix GitHub Actions 2023-09-07 20:38:32 +01:00
w0rp
99a33d8d3f
Try to test ALE on Windows in GitHub 2023-09-07 20:29:35 +01:00
w0rp
108e858d61
Update minimum supported NeoVim version to 0.6.0
Stop officially supporting NeoVim versions below 0.6.0, without
necessarily breaking ALE for people using older versions.
2023-09-07 20:01:31 +01:00
w0rp
14350dbb0d
Close #3368 - Supercharge :ALEInfo
Make a series of sweeping changes to make :ALEInfo more useful.

1. Deprecate :ALEInfoToClipboard and support :ALEInfo -clipboard
2. Permit :ALEInfo -clip as a shorthand for :ALEInfo -clipboard
3. Support :ALEInfo -preview to render in the preview window
4. Support :ALEInfo -echo for the classic :ALEInfo mode
5. Change the default mode to 'preview', and make it configurable
6. Add syntax highlighting for ALEInfo in preview mode
7. Add a convenience to look up documentatation that explains itself
8. Don't show an empty 'Linter Variables' section
2023-09-06 00:21:58 +01:00
w0rp
551fbcfb09
Add an option to save hidden buffers
When commands are run, it can be useful to just save the hidden buffers
so language servers immediately get updated with changes to files
without you having to manually save each file. You can now enable this
by setting `g:ale_save_hidden` to `1`.
2023-09-06 00:17:27 +01:00
w0rp
8ba7ae818c
Close #4461 - Use rust-analyzer by default
Use rust-analyzer by default instead of rls, as rls has been deprecated.
2023-09-05 21:45:34 +01:00
Henrique Barcelos
64ddf457e1
Feature: add forge fmt as a fixer for Solidity files (#4598)
* feat: add `forge fmt` as a fixer for Solidity
2023-09-05 18:34:39 +01:00
Magnus Groß
59e455b4d8
Improve ALEFix performance for neovim (#3974)
* Avoid performance problems with setbufline() and Treesitter

Call nvim_buf_set_lines() instead.

Since this is a performance problem only in Neovim (Treesitter is only
available there), it doesn't matter that this API is unavailable in Vim.

Note: nvim_buf_set_lines() returns E5555, when set nomodifiable is on.

Fixes #3669

* Avoid sign flickering

The signs flickered because nvim_buf_set_lines() removes all signs from
lines that it touches, which will immediately be readded by Ale (causing
the brief flicker). This is intended behaviour in neovim [0].

Neovim itself faced this problem in their own LSP formatting sync,
although they had the problem with marks instead of signs [1].
Similar to how neovim fixed it by storing and restoring the marks [2],
we can do the same thing with signs.

In fact it is easier with signs, because sign_placelist() will just
ignore and skip invalid line numbers, so we don't need to filter signs
that are not valid anymore.

[0] https://github.com/neovim/neovim/issues/10880#issuecomment-526466042
[1] https://github.com/neovim/neovim/issues/14307
[2] https://github.com/neovim/neovim/pull/14630
2023-09-05 14:36:17 +01:00
xu0o0
ea27441834
fix(neovim): ignore unrelated diagnostics (#4597)
Fix the NeoVim diagnostics bridge so it only sends over diagnostics relevant to the current buffer.
2023-09-05 14:34:33 +01:00
Peter Benjamin
3bedafc29a
fix(yaml): make actionlint respect config (#4584)
* fix(yaml): make actionlint respect config
* docs: update actionlint docs
* chore: update author & add description
* test: move actionlint test to test/linter/
2023-09-05 14:33:41 +01:00
jiz4oh
115ad17ace
Support format xml file which haven't yet persisted at the disk (#4585)
Support format xml file which haven't yet persisted at the disk
2023-08-20 10:43:31 +01:00
ymap
d1bac104a1
Fix typo in filename (#4595) 2023-08-20 10:33:37 +01:00
Tomáš Janoušek
fe38101db7
Fix error loading "text" syntax for hover (#4574)
rust-analyzer sometimes returns a hover result with language being
"text", but there's no syntax/text.vim, so this would fail with:

    Error detected while processing function <SNR>150_VimOutputCallback[6]..<lambda>8[1]..ale#lsp#HandleMessage[30]..ale#hover#HandleLSPResponse[42]..ale#floating_preview#Show[13]..<SNR>161_VimShow:
    line   13:
    E484: Cannot open file syntax/text.vim

Only including the file when it actually exists fixes this.
2023-08-15 11:20:47 +01:00
Matheus Werny
951b280bd5
yamlfmt (#4587)
* Added the fixer, wrote tests and tested it
2023-08-15 10:15:06 +01:00
Rodrigo Mesquita
15cbc0e912
Close #4579 - Support numhl highlights for vim >= 8.2.3874
In #2637, support for numhl highlights was added for nvim.

In the meantime, vim added support for numhl highlights in patch 8.2.3874.

This patch allows numhl highlights to be enabled in ALE for vim >= 8.2.3874 too.
2023-08-05 18:10:03 +01:00
Oskar Haarklou Veileborg
af42e0b510
floatwin: use win_execute in NeoVim for commands when it exists (#4532) 2023-08-01 21:30:23 +01:00
Peter Benjamin
0bc2ea0800
docs: fix typo (#4567)
Closes #4517

Co-authored-by: Peter Benjamin <peterbenjamin@peters-mbp.lan>
2023-08-01 21:23:53 +01:00
Peter Benjamin
18cd44c57d
feat(markdown): add marksman lsp (#4565)
* feat(markdown): add marksman lsp
* docs: add marksman docs
* test(markdown): add marksman test

Co-authored-by: Peter Benjamin <peter.benjamin@peter.benjamin-FVFHP2WSQ05Q>
2023-08-01 21:23:02 +01:00
Amadeus Demarzi
1174b3b81e
Don't echom if not in normal mode (#4560) 2023-07-31 08:39:30 +01:00
Wooter
b216892f0c
Communicate support for markdown to the lsp server (#4450) (#4453) 2023-07-25 10:43:57 +01:00
JoseGRuiz
481c5cccbf
fixed parsing errors when certain options are used in glslangValidator (#4540)
* fixed parsing errors when certain options are used in glslang

* Update glslang.vim

set column number to 0 like it is always set by glslangValidator

* Added a test for the handler of glslangValidator
2023-07-24 21:43:13 +09:00
Arash Mousavi
93a4f70414
Add erb-formatter support (#4546) 2023-07-24 21:38:52 +09:00
Craig Rodrigues
3d10770387
Remove gometalinter support (#4534)
gometalinter has been deprecated, and was archived in 2019
2023-07-24 21:33:15 +09:00
Craig Rodrigues
f34016a552
feat: enable golangci-lint by default (#4536)
This replaces golint and gometalinter which are both deprecated
2023-07-24 21:30:00 +09:00
LittleKey
969f7b080f
Add end_col of matched forbidden word (#4556) 2023-07-24 10:37:49 +09:00
Mitchell Hanberg
7ba88ad343
chore: update elixir_ls.vim (#4547)
The project was forked and lived under a new organization
2023-07-24 10:28:34 +09:00
Arnold Chand
32e1417d98
fix(vue): volar v1 support (#4552)
* fix: volar v1 support

* fix: volar linter errors
2023-07-24 10:08:11 +09:00
Ben Boeckel
1084152a11
ale-rust: add an example for rust-analyzer configuration (#4559)
Closes: #4557
2023-07-24 09:35:54 +09:00
Craig Rodrigues
29e5ffe35a
Remove golint supported-tools (#4535)
golint has been deprecated and was archived in 2019
2023-06-27 18:52:50 +09:00
Chuck Grindel
21f1ab6ffc
feat: support Bazel buildifier linter (#4529)
* Initial buildifier linter files

* Add handler test

* Fix test when options are not set
2023-06-27 18:52:25 +09:00
0xHyoga
5ab35a7a30
Update cairo linter to Cairo 1.0 (#4530)
* update cairo linter

* new cairo handler test

* add another handler instead of replacing
2023-06-27 18:44:20 +09:00
Nathan Henrie
c0eff9f2f1
Mention deadnix in supported tools (#4528)
Deadnix support was added in
https://github.com/dense-analysis/ale/pull/4443 but it seems not to have
been mentioned in the lists of supported tools.
2023-06-09 10:56:53 +09:00
Rob Whittaker
7021ed0c68
🐛 Fix a Ruby deprecation warning in the ERB linter (#4521)
* Fix a Ruby deprecation warning in the ERB linter

Before, the ERB linter used positional arguments. Newer versions of Ruby
have deprecated this method signature. We fixed the linter to use
keyword arguments.

* fixup! Fix a Ruby deprecation warning in the ERB linter
2023-05-26 14:52:51 +09:00
Shad
a46121a532
Dockerlinter (#4518)
* dockerlinter support

* Tests & ShellCheck reference

* sort and align docs
2023-05-22 11:58:59 +09:00
bretello
5c803fb970
docs: fix broken link for ccls init opts (#4520)
Co-authored-by: bretello <bretello@distruzione.org>
2023-05-21 14:11:15 +09:00
lucas-str
9fe9f11521
Add support for npm-groovy-lint (#4495)
* Add support for npm-groovy-lint

* Add doc and tests for npm-groovy-lint

* Use ale#util#FuzzyJSONDecode instead of json_decode
2023-05-06 09:02:07 +09:00
Pat Brisbin
61248e1453
Add fourmolu fixer (#4501)
* Add fourmolu fixer

Fourmolu is aversion of Ormolu that supports configuration. This fixer
was modeled after the Ormolu one, but using the "stack executable"
approach of the Brittany and Stylish Haskell fixers.

* Sort supported-tools.md
2023-04-22 22:05:50 +09:00
Horacio Sanson
fdadaed2ba
Fix 4490 - Fix pyright not running with poetry (#4491)
* Fix 4490 - Fix pyright not running with poetry

* Fix tests
2023-04-13 08:54:49 +09:00
Carl Smedstad
93100159a2
Add support for Bicep when installed as a plugin to Azure CLI (#4496)
* Add support for Bicep when installed as a plugin to Azure CLI

The compiler for Microsoft's DSL Bicep can be installed both
independently and as a plugin to Azure CLI. The latter is probably how
most people install it.

The program output is the same but Azure CLI wraps the arguments and has
a slightly different interface, hence I opted to copy the old linter and
modify it to match the plugin arguments.

* Fix bicep/az_bicep tests, arguments and parsing

* Actually test the ale_linters#bicep#az_bicep#Handle function in the
  test that should test that function, not
  ale_linters#bicep#bicep#Handle.

* Use the same method as in bicep/bicep for discarding output file, i.e.
  by specifying --outfile to a null file.

* Fix parsing of occasionally occurring leading error type (such as
  'ERROR: ').

* Correct option defaults for bicep & az_bicep specified in documentation
2023-04-13 08:51:52 +09:00
SkrrtBacharach
57254db9ef
Fix error from ansible-lint versions >=6.11.0. (#4492)
* Fix error from ansible-lint versions >=6.11.0.

The JSON output format of ansible-lint has changed since
6.11.0. Issue locations can have either a 'positions' or
a 'lines' member, rather than just a 'lines' member as it
was before. This fix checks which member is present, and
passes that member name to subsequent dictionary lookups.

The error was caused by the following change:
https://github.com/ansible/ansible-lint/pull/2897

* Add ansible-lint test to check each type of ansible-lint issue json.

* Change long single-line JSON in ansible test into multiline JSON.

* Fix linting errors in ansible_lint.vim.
2023-04-07 09:19:58 +09:00
Veselin Ivanov
b0ba31f88e
remove --enable-all from golangci-lint options (#4488)
* remove --enable-all from default golangci-lint options

* update golangci-lint options documentation

* update tests to use empty golangci-lint options
2023-04-02 18:09:58 +09:00
David le Blanc
41e12fd640
Added column alignment for errors (#4473) 2023-03-31 10:50:48 +09:00