Commit Graph

1553 Commits

Author SHA1 Message Date
Adam Blackwater
50e237facd
Fix: Ruff output option (#4632)
* fix --output-format option
* Add conditionally changing flag based on Ruff version
2023-11-08 21:44:11 +00:00
w0rp
53b01d6a54
Fix #4499 - Fix solhint >= 3.4.0
Fix solhint for versions >= 3.4.0, while still supporting older
versions.

The solhint linter code has been moved out of the `handlers` directory
as it does not need to be shared between different filetypes. Code has
been simplified.

Co-authored-by: Henrique Barcelos <16565602+hbarcelos@users.noreply.github.com>
2023-09-17 17:24:23 +01:00
w0rp
bd9fc580a1
Close #4541 - Fix Haskell project root detection
We weren't joining and returning paths correctly for detecting project
roots for Haskell projects, and now we are.

Co-authored-by: Rodrigo Mesquita <rodrigo.m.mesquita@gmail.com>
2023-09-16 23:25:39 +01:00
w0rp
ae1d051504
#4454 Clean up more tests and code
* Remove some tests we no longer need
* Delete blocks of redundant code
* Compress some tests together to simplify them
* Remove a little code for ancient linter versions
* Escape more executables we didn't escape before
* Rename a deno option that didn't match our conventions
2023-09-16 22:23:30 +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
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
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
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
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
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
Craig Rodrigues
3d10770387
Remove gometalinter support (#4534)
gometalinter has been deprecated, and was archived in 2019
2023-07-24 21:33:15 +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
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
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
Albert Peschar
6ae26df22b
Add deadnix linter (#4443) 2023-03-07 01:31:14 +00:00
javad
f78e9d634f
Add support for llvm-mc as an assembly linter (#4446) 2023-02-09 10:49:24 +09:00
w0rp
4c162877e2
#2172 Auto PATH with ale_python_auto_virtualenv
Automatically set `PATH` for some Python linters that seem to need it
when g:ale_python_auto_virtualenv or b:ale_python_auto_virtualenv is
`1`.
2023-02-08 09:11:31 +00:00
w0rp
6ff1f0b200
Close #4389 - Run pyright via poetry, pipenv, venv
Add support for automatically detecting and running Pyright via poetry,
pipenv, and virtualenv directories just like we do with flake8.
2023-02-08 08:24:16 +00:00
w0rp
f2a21c960a
Add support for lua-language-server 2023-02-08 01:14:47 +00:00
vindex10
98f466f9ce
add eslint plugin html for linting js in html files (#4428)
* add eslint plugin html for linting js in html files

* fix linting
2023-02-02 14:13:52 +09:00
Albert Peschar
599f7b1eda
phpstan: set cwd to configuration file directory (#4422)
PHPStan will only detect a configuration file in the current working
directory, so set that to the directory in which ALE finds the
configuration file.
2023-02-02 14:09:11 +09:00
Yining
b6f6d84c25
add: pycln as a python linter and fixer (#4415)
this commit adds pycln as a Python linter and fixer, together with some
tests and documentation. It addresses #4340

pycln repo: https://github.com/hadialqattan/pycln
2023-01-27 10:24:18 +09:00
Actionless Loveless
26c79014f5
fix(ale_linters: python: ruff): add --stdin-filename if version > 0.0.69 (#4414) 2023-01-27 09:03:41 +09:00
Antonio Gurgel
ef6715ee41
nix: durably handle versions before 2.4 (#4398)
What I should have done in 4394. Idea: @w0rp
2022-12-28 21:05:32 +09:00
Antonio Gurgel
4c5c47b593
nix: handle versions past 2.9 (#4394) 2022-12-25 19:02:01 +09:00
w0rp
bc95701575
Fix #4388: Fix pylsp and Pyright cwd
Add functions to compute the cwd to be the same as the project root for
pylsp and Pyright to work around issues in each language server when
they encounter modules that share the same name as first or third party
libraries.
2022-12-24 13:37:57 +00:00
Michael F. Schönitzer
42a17dec16
Handle empty answer of ansible-lint (#4373)
* Handle empty answer of ansible-lint

The variable a:lines might be empty if ansible-lint exited early, in
that case json_decode would trow an error.

* Use ales JSON decode function
2022-12-06 21:44:10 +09:00
Yining
cad8f8e683
add: support for refurb as a Python linter (#4379)
this commit adds refurb as a Python linter, together with some tests
and documentation. it should fix issue: #4362

refurb repo: https://github.com/dosisod/refurb
2022-12-06 21:26:09 +09:00
Horacio Sanson
3e460fa93b
Fix 4246 - Add ansible language-server (#4355) 2022-11-25 13:13:38 +00:00
Carl Smedstad
590352304e
Fix bug in sqlfluff implementation & implement fixer support (#4365)
* Account for no sqlfluff output

Avoid crashes when there isn't any output from sqlfluff.

* Add supplort for sqlfluff as a fixer
2022-11-23 19:58:49 +09:00
Carl Smedstad
6c4be47437
Implement support for SQL linter sqlfluff (#4361) 2022-11-21 19:50:45 +09:00
Götz Christ
ca355f4cb4
Markdown: allow passing custom executable for markdownlint (#4358) 2022-11-21 19:47:05 +09:00
Yining
edffffac25
add: support config option for checkmake linter (#4351)
`checkmake` by default checks config file "in the same folder it's
executed in" unless `--config` option is set.

This commit allows setting the `--config` option with an option
variable (with documentation updated).
2022-11-06 09:32:51 +09:00
Matthew Armand
121fbefeae
Add 'dockerfile_hadolint_options' config setting (#4353)
- Add this option so command line arguments can be supplied to hadolint
- This will be respected when running in docker and via the executable
- Preserve the --no-color and - flags, and add these to the list
- Add to docs and tests
2022-11-04 17:07:56 +09:00
Yining
483d056528
add: support for ruff as a Python linter and fixer (#4347)
this commit adds ruff as both a Python linter and fixer, together with
some tests and documentation.

ruff repo: https://github.com/charliermarsh/ruff
2022-10-31 21:55:14 +09:00
Dmitri Vereshchagin
06efbdd25a
Add erlang_ls linter for Erlang files (#4346) 2022-10-29 20:58:30 +09:00
Ben Boeckel
28cff80652
codespell: fix spelling errors picked out by codespell (#4343) 2022-10-29 20:56:09 +09:00
Nicolas Pauss
951a668b14
cc: fix using '-x c*-header' for header files with GCC. (#4334)
Gcc does not support `x c*-header` when using `-` as input filename,
which is what ALE does.

Rework the feature to only use `-x c*-header` flag when using Clang and
not GCC.

The feature is now also controlled with the variable
`g:ale_c_cc_use_header_lang_flag` and
`g:ale_cpp_cc_use_header_lang_flag`.
2022-10-12 07:05:37 +09:00