Commit Graph

2299 Commits

Author SHA1 Message Date
w0rp
cf270a1ada
Stop supporting ale_lsp_root
We renamed the ale_lsp_root setting to ale_root long ago. Stop
supporting the old setting name.
2023-09-16 17:17:42 +01:00
w0rp
1799f8bec6
Close #4458 - Add an ALEStopLSP command
Add an ALEStopLSP command to stop all language servers that match a
given name. Completions are available for the command. This makes it
possible to keep other language servers running other than the one
you're interested in stopping.
2023-09-16 17:03:02 +01:00
w0rp
be69af2705
#4607 No conflicts with nvim-lspconfig by default
Default `g:ale_disable_lsp` to a new mode `'auto'` by default. With this
setting applied, ALE will now check for the presence of nvim-lspconfig
and automatically turn off particular LSP linters if already configured
via nvim-lspconfig.

For users that do not use `nvim-lspconfig`, everything should work as
before.
2023-09-14 00:40:56 +01:00
ymap
9092af9ad6
Add support for Packwerk (#4594)
Packwerk (https://github.com/Shopify/packwerk) is a Ruby gem
used to enforce boundaries and modularize Rails applications.
2023-09-13 15:53:24 +01:00
Axel Clark
ac615e7f65
Add lexical for linting elixir projects (#4580) 2023-09-11 13:48:11 +01:00
w0rp
1bf445c6d5
Print the most severe problem with virtualtext
Fix the ordering of virtualtext so we print the most severe problem on a
line. If two problems are the most severe, we will print the left-most
problem.
2023-09-10 17:44:25 +01:00
w0rp
385dc4130c
Show a single virtualtext message by default
Show only a single virtualtext message per line by default. The setting
can be configured to whatever the user wants. This default prevents
several linters from spamming the editor with messages that run off into
the right margin.

Documentation now clarifies that problems have a predictable order, and
which message will come first.
2023-09-10 17:22:16 +01:00
Peter Benjamin
61892e8586
fix(json): update vscode json lsp name (#4601)
* fix(json): update vscode json lsp name
* fix(vscodejson): fallback to previous name

Co-authored-by: w0rp <devw0rp@gmail.com>
2023-09-09 23:28:38 +01:00
w0rp
92267a14ba
Remove backwards compatibility with ancient setting names 2023-09-09 23:13:44 +01:00
w0rp
a16f060481
Close #4442 - Use Neovim diagnostics by default
Use Neovim's diagnostics API by default in recent enough Neovim
versions. This will make problems found by ALE play nicely with problems
found by other tools.
2023-09-09 16:34:55 +01:00
w0rp
d2c2bbf2dc
Add --globals vim to luacheck automatically
luacheck will run with `--globals vim` automatically if the file is in
runtimepath and `--globals` hasn't already been configured.
2023-09-09 14:01:00 +01:00
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
9713faf192
Attempt running Windows rests relative to GitHub dir 2023-09-07 20:47:20 +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
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
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
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
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
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
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
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
Guillermo R. Roig Carralero
7dbd3c96ac
Add support for rustywind fixer (#4477) 2023-03-26 15:38:24 +09:00
Wilson E. Alvarez
e1a0781f9d
Fix ale#util#GetBufferContents and propagate use (#4457)
* Use newline characters instead in ale#util#GetBufferContents
* Propagate use of ale#util#GetBufferContents
* Add ale#util#GetContentBuffer test
2023-03-14 20:55:28 +00:00
w0rp
96f0bf7172
Fix windows virtualenv PATH tests 2023-03-07 02:11:43 +00:00
w0rp
bb691d6dee
#2172 - Expand PATH in the shell for automatic virtualenv 2023-03-07 01:59:11 +00:00
Albert Peschar
6ae26df22b
Add deadnix linter (#4443) 2023-03-07 01:31:14 +00:00
w0rp
c3f9bccb8c
Ignore shellcheck error in run-vader-tests 2023-02-13 04:43:45 +00:00