Commit Graph

2207 Commits

Author SHA1 Message Date
Horacio Sanson d511d5af11 Fix 2726 - fix terraform linter.
Instead of using `terraform fmt` for linting use `terraform validate`
with json output.
2021-01-30 17:20:44 +09:00
Horacio Sanson 64d430438e Fix 3371 - Add terraform-ls support 2021-01-30 16:09:39 +09:00
w0rp 82c8e3a3a3
Remove last traces of Travis CI
* The build status badge is now for GitHub Actions.
* The documentation now mentions GitHub instead.
* Warnings in the YAML file have been fixed or ignored.
2021-01-27 20:11:46 +00:00
Horacio Sanson bafe1c0fd6
3560 add vim 8.2 and nvim 0.4 to ci tests (#3561)
* Add vim82 and neovim04 to CI tests.

* Fix test_sign_column_hightlighting test.

In vim82 with verbose=1 the output of highlight command changes breaking
the ale#sign#SetUpDefaultColumnWithoutErrorsHighlight(). This commit
forces verbose=0 when the method starts and restores the previous value
before exiting.

* No return values in vim82 returns a numeric value instead of a empty string.

* Fix test_reek_handler test

The FuzzyJSONDecode() method catches E474 when it fails to parse the
input as JSON but Vim8.2 throws E491 instead. This commit modifies the
function to catch both E474 or E491.

* Fix perl6 handler test.

Perl6 handler catches json parse errors using the E474 error but in
Vim82 it changed to E491. This commit modifies the handler so both
errors are considered.

* Fix list opening tests.

In Vim 8.2 the call `range(1, bufnr('$'))` always returns quickfix
buffers no matter if they are closed or not. Using `ls` does not show
them but the above range will always include them.

This new behavior breaks the ale#list#IsQuickfixOpen() method that in
turn breaks many other things. This commit fixes this by using the
getqflist() and getloclist() methods instead.

* Fix test updates loclist test.

For some reason in Vim 8.2 the sign offset seems to not reset between
tests causing the sign_id to not match in the Assert. When the test is
run individually it passes but when run as part of the whole suite the
sign_id is off by one.

Forcing the offset in the test setup seems to fix the issue.

* Fix omnifunc completion test.

For unknown reasons the SetCompletionResponse tests fail in Neovim 0.2
and 0.4. Unfortunatelly the only solution I found is to disable them
for neovim.

* Fix linter warnings

* Fix smoker test.

Add vim 8.2 to the list of versions that need some retires due to
randomly failing tests.

* Add docker image build job.

Trying some clever trick to build the docker image if not available
locally or in Docker hub. It uses the Dockerfile md5 checksum as tag so
only when changes on that file occur will the image be downloaded or
build.

* Add labels to Docker image

* Remove tests for middle versions 8.1 and 0.3.5

* Use same vader commit as appveyor

* Implement image push to Docker Hub

Co-authored-by: Horacio Sanson <horacio@allm.inc>
2021-01-27 19:52:24 +00:00
Horacio Sanson c9f4005820
Merge pull request #3425 from pinicarus/custom-dialyzer-options
Custom erlang/dialyzer options
2021-01-27 20:24:26 +09:00
Kevin Svetlitski cab4280d02
Feature: Add support for named-pipe sockets for LSPs (#3509)
* Add support for using named pipes for lsp 'socket' servers; documentation updated accordingly
* Add tests for connecting to named pipe sockets
2021-01-26 20:43:17 +00:00
Horacio Sanson 3a1728297a
Merge pull request #3227 from Ma27/nixunstable-error-fmt
Update error-parser for `nix-instantiate` on Nix 2.4+
2021-01-25 13:53:09 +09:00
Maximilian Bosch 72dbd7f648
Update error-parser for `nix-instantiate` on Nix 2.4+
In the (unreleased) Nix 2.4 the error-messages have been reformatted[1].
This patch aims to retain proper `.nix`-support in `ale`, for both
stable Nix (2.3 and older) and unstable Nix (2.4 and newer).

[1] https://github.com/NixOS/nix/pull/3590
2021-01-24 22:54:02 +01:00
Horacio Sanson 18eb6a0758
Merge pull request #3557 from benknoble/dafny-filename-again
dafny: update filename handling
2021-01-24 14:07:12 +09:00
Pierre-Nicolas Clauss 105bc55695
refactor(erlang/dialyzer): remove file placeholder from options
Signed-off-by: Pierre-Nicolas Clauss <pinicarus@protonmail.com>
2021-01-23 19:07:26 +01:00
Pierre-Nicolas Clauss 0ac7595fe9
Merge remote-tracking branch 'upstream/master'
Signed-off-by: Pierre-Nicolas Clauss <pinicarus@protonmail.com>
2021-01-23 19:06:59 +01:00
D. Ben Knoble bacb8bb902 dafny: update filename handling
cf. #3475, #3390
2021-01-23 12:34:36 -05:00
D. Ben Knoble 2c1c5b06d9 Merge branch 'master' into fix-swipl
* master: (133 commits)
  Add rnix-lsp for Nix diagnostics and completion
  add spectral support for json
  add spectral handler
  add spectral linter for yaml
  doc: Fix linter issues
  doc: Add documentation for Deno
  feat: Add Deno lsp support
  feat: Add Deno fmt fixer
  Add document for apkbuild filetype
  Add tests for atools handler, basic and dealing with Error and Warning
  Test default linters for apkbuild
  Document new default linters for apkbuild
  Make apkbuild_lint and secfixes_check default for apkbuild filetype
  document support for apkbuild-lint and secfixes-check for apkbuild
  Add linters for apkbuild-lint and secfixes-check from atools
  Add handler for the output of atools
  Fix typos
  Add command callback tests
  Add support for standalone files
  Fix linting errors
  ...
2021-01-23 12:29:05 -05:00
Horacio Sanson 9fd9435cd5
Merge pull request #3556 from jD91mZM2/rnix
Add rnix-lsp for Nix diagnostics and completion
2021-01-23 21:50:36 +09:00
jD91mZM2 c1b6628425
Add rnix-lsp for Nix diagnostics and completion 2021-01-23 13:23:14 +01:00
Horacio Sanson 3e94c42ec0
Merge pull request #3521 from hsanson/3498-change-standardrb-fixer-to-use-stdin
3498 change standardrb fixer to use stdin
2021-01-23 19:28:41 +09:00
Horacio Sanson a6dfc611f6
Merge pull request #3424 from maxice8/atools
Add support for Alpine Linux APKBUILD
2021-01-23 16:05:26 +09:00
tatsuya 997dd7f8fe add spectral handler 2021-01-23 11:56:10 +09:00
tatsuya 5a47d878fb add spectral linter for yaml
ci
2021-01-23 11:56:10 +09:00
Horacio Sanson c374736301
Merge pull request #3533 from motato1/master
Deno support for LSP and fixer
2021-01-23 11:04:52 +09:00
Horacio Sanson 5200e6c734
Merge pull request #2825 from thindil/master
Added support for Ada Language Server
2021-01-23 09:41:02 +09:00
Mohammed Chelouti e16c3b09f7 doc: Add documentation for Deno 2021-01-22 19:06:53 +01:00
Mohammed Chelouti 9b362634f7 feat: Add Deno lsp support 2021-01-22 19:06:53 +01:00
Mohammed Chelouti 4f2666265a feat: Add Deno fmt fixer 2021-01-22 19:06:52 +01:00
Leo 56951932e0 Add tests for atools handler, basic and dealing with Error and Warning 2021-01-22 14:04:26 -03:00
Leo 4999ae2e85 Test default linters for apkbuild 2021-01-22 14:04:26 -03:00
Horacio Sanson 33f2f8ddcd
Merge pull request #3551 from fenuks/bugfix-3506
Fix clang-tidy ignoring compile-commands.json
2021-01-23 01:55:40 +09:00
Bartek thindil Jasicki 1ca780a08a Merge remote-tracking branch 'upstream/master' 2021-01-22 17:52:01 +01:00
Nelson Yeung efe65f3477 Add command callback tests 2021-01-22 16:37:38 +00:00
Horacio Sanson 9a1e91e075
Merge pull request #3519 from atsuya/feature/support-vala-lint
Add support for Vala-Lint
2021-01-23 01:24:24 +09:00
Charles B Johnson 5fd5fa5305
linters/xo: fix tests 2021-01-22 09:23:54 -06:00
Charles B Johnson 23ff19a162
fixers/xo: remove unnecessary directory crawl 2021-01-22 09:23:54 -06:00
Charles B Johnson f17beadb49
fixers/xo: support monorepos 2021-01-22 09:23:54 -06:00
Charles B Johnson 8ffde14039
fixers/xo: support stdin relative to the fixed file 2021-01-22 09:23:53 -06:00
Charles B Johnson e75ac9f497
fixers/xo: support typescript options 2021-01-22 09:23:53 -06:00
Charles B Johnson 289f808ccd
fixers/xo: refactor to handlers 2021-01-22 09:23:53 -06:00
Charles B Johnson 4a6136c27e
fixers/xo: add tests 2021-01-22 09:23:53 -06:00
Charles B Johnson 6bfcb9cdff
linters/xo: consolidate xo linters 2021-01-22 09:23:53 -06:00
Atsuya Takagi 2dbf4ee271 add test to check if it properly ignores outputs with unknown error types 2021-01-23 00:08:01 +09:00
Atsuya Takagi 4ed520a219 add initial files 2021-01-23 00:08:01 +09:00
fenuks 65824feef3 Fix clang-tidy ignoring compile_commands.json 2021-01-22 15:19:38 +01:00
Horacio Sanson 014b00d4d7 Add yamllint and prettier to openapi.
This commit enables yamllint and prettier on openapi files.
2021-01-22 23:17:38 +09:00
Horacio Sanson 03eae9e085 Fix 2777 - Add IBM openapi validator 2021-01-22 23:17:38 +09:00
Horacio Sanson 27a22e7161 Update tests 2021-01-22 23:17:01 +09:00
Bartek thindil Jasicki 42bf5ca911 Merge remote-tracking branch 'upstream/master' 2021-01-22 09:45:52 +01:00
Horacio Sanson 80a0108fcf prolog/swipl: cover new format with complex tests
https://github.com/dense-analysis/ale/pull/3377#issuecomment-763628447
2021-01-20 12:08:05 -05:00
Horacio Sanson 7e3d2930d8
Merge pull request #3261 from toastal/dhall
Enhanced Dhall fixer support
2021-01-20 21:06:03 +09:00
Horacio Sanson 7b42dd7387
Merge pull request #3475 from benknoble/dafny-include-timeouts
dafny: add a timeLimit option and message-parsing
2021-01-20 20:48:53 +09:00
Horacio Sanson 16c45b8213
Merge pull request #3453 from blinsay/blinsay/rust-analyzer-lsp
pass lsp intialization_options to rust-analyzer
2021-01-20 20:45:17 +09:00
Horacio Sanson 8de0e7b9ba
Merge pull request #3430 from mbrunnen/mbn/fix-macros-include-c-flag
Add -imacros to C flags
2021-01-20 20:42:18 +09:00
Horacio Sanson 783cf4ab82
Merge pull request #3362 from daliusd/tsserver_hints
Show tsserver hints/suggestions in Ale.
2021-01-20 20:40:44 +09:00
Horacio Sanson bfc412a77b
Merge pull request #3455 from Thau/feat/credo_config_file
feat: Adds variable to use custom config file with Elixir Credo
2021-01-20 08:42:45 +09:00
Horacio Sanson 9387ccfbc5
Merge pull request #3485 from andreaconti/master
Fix Julia Language Server Support
2021-01-16 15:58:21 +09:00
Bartek thindil Jasicki 45a28383a2 Merge remote-tracking branch 'upstream/master' 2021-01-15 09:42:14 +01:00
w0rp f398faa8d3
Merge pull request #3471 from kevinclark/3448-fix-unittests
Make test/scripts/custom-checks portable
2021-01-14 18:08:44 +00:00
Kevin Clark 39f393ef07
Add nvim floating window support (replaces #3314) (#3470)
* Add nvim floating window hover support
* Add configuration for float to replace preview
* preview#ShowFloating: qualify local variables
* Configure floating preview usecases individually

Also:
  * Extract floating preview to its own file.
  * Ignore 'stay_here' option. Moving into the floating preview window
    seems confusing at best.
  * Re-use existing floating preview window if it's still up.
  * Flush out floating preview documentation.

* Watch cursor position changes per window

Floating previews open a new window, so when that window is written to,
it moves briefly there at a different position than the original window.
This makes repeated positions detected when positions are tracked at a
s: level. Instead, we change the variable to window scoped, which only
fires a message if the cursor has changed from the last position in
*that window*.

* g:ale_floating_preview cleanup
* floating_preview: add ALEDetail tests
* Fix fecs test missing runtime call
* Add ALEHover floating preview tests

Co-authored-by: Jan-Grimo Sobez <jan-grimo.sobez@phys.chem.ethz.ch>
2021-01-14 18:06:20 +00:00
Horacio Sanson 97ce2423b0
Merge pull request #3494 from YorickPeterse/master
Add linter for Inko
2021-01-13 23:54:06 +09:00
Horacio Sanson 012348582c
Merge pull request #3531 from pinicarus/custom-erlc-executable
Custom erlc executable
2021-01-13 14:04:58 +09:00
Bartek thindil Jasicki 7b1ed2733e Merge remote-tracking branch 'upstream/master' 2021-01-08 09:43:19 +01:00
Horacio Sanson 54dd731cf1
Merge pull request #3386 from ivorpeles/master
Make isort fixer recognize auto_pipenv flag
2021-01-08 10:43:34 +09:00
Horacio Sanson 4c454c96a9
Merge pull request #3390 from benknoble/fix-dafny-filename
dafny: include correct filename in lint results
2021-01-06 11:19:29 +09:00
Kevin Clark 6b97af680d Exclude grandfathered-in non-snakecased lints
Prior to #3448, several linters should have been failing the
custom-checks that look for non-snake-cased lint names. They weren't,
but now the bug that hid those is fixed. So to avoid breaking users, we
just exclude those from the check. Linters excluded:

  * clojure/clj_kondo.vim
  * elixir/elixir_ls.vim
  * go/golangci_lint.vim
  * swift/swiftformat.vim
2021-01-01 14:48:10 -08:00
Yorick Peterse 8375ee2766
Add linter for Inko
This adds a linter for Inko (https://inko-lang.org/). The linter makes
use of Inko's own compiler, and a newly introduced --check flag to only
check for errors; instead of also compiling source code.
2020-12-23 16:50:45 +01:00
Manoel Brunnen 02255dd967 Add tests for -imacros C flag 2020-12-21 15:07:11 +01:00
toastal 9c7e1fe4dd
merging master 2020-12-21 10:26:09 +07:00
Bartek thindil Jasicki 8af805cefe Merge remote-tracking branch 'upstream/master' 2020-12-18 10:04:19 +01:00
Benjamin Binier e358afdd9b Add salt-lint support 2020-12-17 09:19:19 +01:00
Horacio Sanson f996ede599
Merge pull request #3403 from will/sorbetwatchman
Add Ruby sorbet option to enable watchman
2020-12-16 09:48:35 +09:00
Andrea Conti 6043eeb25a Fix test space bug 2020-12-12 00:41:05 +01:00
Andrea Conti fa2186d95e Update Julia language server run command 2020-12-12 00:16:09 +01:00
Bartek thindil Jasicki b85207d524 Merge remote-tracking branch 'upstream/master' 2020-12-04 09:45:06 +01:00
D. Ben Knoble 7e12be0c64 Merge remote-tracking branch 'origin/master' into fix-swipl
* origin/master: (40 commits)
  fix: correct suggested filetype for yamlfix
  feat: add yamlfix fixer
  Use _config for LSP config options
  Add support for R languageserver (#3370)
  Fix 3103 - add shellcheck shell directive detection. (#3216)
  Added the Vundle command in installation instructions (#3400)
  Adds support for Tlint - A Tighten Opinionated PHP Linter (#3291)
  Add php phpcbf options (#3383)
  Use has('gui_running') instead of has('gui')
  Close #2727 - Add a hover-only setting for balloons
  Fix #3332 - Modify everything for rename/actions
  Add a missing blank line in documentation
  Add luafmt fixer (#3289)
  #3442 Fix code fix clangd issue
  Close #1466 - Add GVIM refactor menu support
  Look for node packages in .yarn/sdks as well
  Update documentation for code actions and rename
  cmp forwards, and reverse the code actions
  Support for LSP/tsserver Code Actions (#3437)
  Move the test for buffer-local variables
  ...
2020-11-30 13:42:21 -05:00
D. Ben Knoble 303b89a6b4 add tests 2020-11-30 13:40:57 -05:00
Moritz Röhrich d9b74caf43 hadolint: Recognize message type
Hadolint is in the process of adding the severity of a lint rule to the
commandline output: https://github.com/hadolint/hadolint/pull/501

This change utilizes that to show the severity in vim.
2020-11-29 15:09:47 +01:00
Horacio Sanson 03b6978a27
Merge pull request #3381 from andreypopp/gofmt-stding-stdout
Use stdin/stdout to communicate with gofmt
2020-11-29 18:59:48 +09:00
Kevin Clark 84c95aff9b Restore ls -v flag to check-toc 2020-11-28 09:44:19 -08:00
Kevin Clark 65b09cfa9d Restore use of grep in check-toc 2020-11-28 09:20:50 -08:00
Kevin Clark d52dce2e6f Use docker image for custom-check scripts
NOTE: The custom-linting-rules test fails due to the following (legit)
warnings:

  ale_linters/clojure/clj_kondo.vim:29 Use snake_case names for linters
  ale_linters/elixir/elixir_ls.vim:15 Use snake_case names for linters
  ale_linters/go/golangci_lint.vim:54 Use snake_case names for linters
  ale_linters/swift/swiftformat.vim:56 Use snake_case names for linters

The message wasn't getting printed because docker was explicitly only
being asked to connect stdout (ignoring stderr). Unclear yet why the
error code wasn't getting bubbled up.
2020-11-28 08:26:13 -08:00
Kevin Clark e300a48e13 Fix test/script/check-supported-tools-tables 2020-11-28 08:23:06 -08:00
Kevin Clark 469af2a734 Fix TOC tests
Sort order is slightly different than the headings
2020-11-28 07:55:35 -08:00
Kevin Clark f72e60c12a Fix check-supported-tools-tables check
sed wasn't using -E, so '|' wasn't being handled properly. Seems likely
that's sed-implementation specific, so now it runs through docker's sed
to support portability.
2020-11-27 20:32:51 -08:00
Bartek thindil Jasicki 09b8cc97de Merge remote-tracking branch 'upstream/master' 2020-11-27 13:38:24 +01:00
Ivor Peles 713e53e3f6 Ensure isort / pipenv test conforms to ALE coding standards 2020-11-25 17:51:27 -05:00
Lyz c69d696e1b
feat: add yamlfix fixer 2020-11-25 01:21:53 +01:00
Gonzalo Quero 7e9d4fbfc8 refactor: Move test to the right file 2020-11-23 10:21:09 +00:00
Gonzalo Quero 491ceacb64 fix: Use proper CdPath function in test 2020-11-23 10:08:00 +00:00
Gonzalo Quero 7d8275daf5 chore: Add Elixir Credo tests 2020-11-23 10:08:00 +00:00
Ivor Peles 6efca486e8 Add test for isort with auto_pipenv flag(s) 2020-11-21 19:24:20 -05:00
w0rp 681a6e371d
Use _config for LSP config options 2020-11-21 20:58:34 +00:00
Eric Zhao 9692c0c64c
Add support for R languageserver (#3370) 2020-11-21 20:56:38 +00:00
Horacio Sanson 5458a1b291
Fix 3103 - add shellcheck shell directive detection. (#3216)
* Fix 3103 - add shellcheck shell directive detection.

Searches for shellcheck shell directive to detect dialects for scripts
that do not have shebang.

* Change order of detection of shellcheck dialect

In a situation where the filetype can be wrong (example: something.sh
which is written in bash dialect) and has no hash-bang (since it is
meant to be sourced) then the override specified within the script will
be ignored.

It probably is the most right thing to do if the script author has added
a specific directive; it should trump everything else.

Co-authored-by: Horacio Sanson <horacio@allm.inc>
Co-authored-by: Dino Korah <dino.korah@redmatter.com>
2020-11-21 20:49:31 +00:00
w0rp b4550f361b
Merge pull request #3409 from lyz-code/feat/add-autoimport-support
feat: add autoimport fixer
2020-11-21 20:45:51 +00:00
Jose Soto e1184e31f6
Adds support for Tlint - A Tighten Opinionated PHP Linter (#3291)
Co-authored-by: w0rp <w0rp@users.noreply.github.com>
2020-11-21 20:29:33 +00:00
w0rp 96428425fe
Merge pull request #2903 from davidtwco/ormolu-fixer
Add ormolu fixer.
2020-11-21 20:25:13 +00:00
Dale Jung 2873be2d6a
Add php phpcbf options (#3383)
* Taken from phpcs. add add_php_phpcbf_options #3382
* Updated docs for php_phpcbf_options #3382
* Added tests #3382
2020-11-21 20:19:02 +00:00
w0rp 2e91f0e689
Use has('gui_running') instead of has('gui') 2020-11-21 20:16:32 +00:00
w0rp a139599d39
Close #2727 - Add a hover-only setting for balloons 2020-11-21 20:12:09 +00:00
w0rp 06e7f2195e
Fix #3332 - Modify everything for rename/actions
ALE now just modifies every open buffer for rename and actions, and sets
up a one-time use BufEnter event to reload buffers that are changed so
you don't have to think about what to do with changed buffers.
2020-11-21 19:00:53 +00:00
w0rp e4bfcb44b3
Merge pull request #3357 from creativenull/feat-php-intelephense
feat: add intelephense support for php
2020-11-21 16:18:20 +00:00
w0rp edd96f4414
Merge pull request #3354 from rphln/collapse-whitespaces
Collapse spaces and lines in the completion menu.
2020-11-21 16:16:08 +00:00
zandr e5d16caebe
Add luafmt fixer (#3289) 2020-11-21 15:59:50 +00:00
w0rp 8e28de142a
Merge pull request #3292 from dmitrivereshchagin/add-elvis-handler-for-erlang
Add Elvis handler for Erlang
2020-11-21 15:56:50 +00:00
w0rp df3163223f
Merge pull request #3282 from zanona/master
fix(ale_linters/phpcs): add support for multiline error messages
2020-11-21 15:36:22 +00:00
Dalius Dobravolskas 17c0c3c731
Test fix. 2020-11-21 15:49:42 +02:00
Dalius Dobravolskas c098a07d67
Tests added. 2020-11-21 15:49:41 +02:00
Dalius Dobravolskas d0b5909fd8
#3442 Fix code fix clangd issue 2020-11-21 01:27:27 +00:00
w0rp 7c04ee5c20
Close #1466 - Add GVIM refactor menu support
Code actions and ALERename now appear in the right click context menu
for GVim by default.
2020-11-21 01:18:27 +00:00
Bartek thindil Jasicki f156548c16 Merge remote-tracking branch 'upstream/master' 2020-11-20 10:11:02 +01:00
Ben Linsay ddfc43e774 pass lsp intialization_options to rust-analyzer
fixes #3350
2020-11-18 22:22:16 -05:00
Dalius Dobravolskas 01800a23ad
Support for LSP/tsserver Code Actions (#3437)
* Added tsserver and LSP code action support.
* tsserver refactors support added.
* Handling special case when new text is added after new line symbol.
* ale#code_action#ApplyChanges simplified.
* Initial attempt on LSP Code Actions.
* workspace/executeCommand added.
* Some null checks added.
* Add last column to LSP Code Action message.
* Pass diagnostics to LSP code action.

Previously ApplyChanges code was applied from top-to-bottom that required 
extra parameters to track progress and there was bug. I have changed code
to bottom-to-top approach as that does not require those extra parameters
and solved the bug.

Tested with typescript-language-server and it is working.
2020-11-14 10:15:17 +00:00
toastal 42e4b14861
Merge branch 'master' of github.com:dense-analysis/ale into dhall 2020-11-14 15:03:26 +07:00
pinicarus db96b00720
Merge branch 'custom-erlc-executable' 2020-11-01 11:45:36 +01:00
cyy a49f664aea chang fishindent to fish_indent 2020-10-31 14:01:08 +08:00
cyy 9d1a71a5cb add doc and test 2020-10-31 14:01:08 +08:00
pinicarus 62f2c6d326
test(erlang/erlc): simplify matches 2020-10-28 12:58:15 +01:00
pinicarus 7d69cdf4ad
test(erlang/erlc): make quotes optional in matches 2020-10-28 12:51:38 +01:00
pinicarus 15f44933c2
feat(erlang/erlc): add option for custom executable 2020-10-28 12:38:28 +01:00
Lyz 513e6ee972
feat: add autoimport fixer 2020-10-23 18:53:38 +02:00
David Wood b496c4b164
Add ormolu fixer.
This commit adds a fixer for the Haskell language, ormolu
(https://github.com/tweag/ormolu).

Signed-off-by: David Wood <david@davidtw.co>
2020-10-23 11:48:21 +01:00
Will Leinweber cafe8621e2 Add Ruby sorbet option to enable watchman 2020-10-20 23:13:53 -07:00
Bartek thindil Jasicki b84d41f9ea Merge remote-tracking branch 'upstream/master' 2020-10-16 17:51:08 +02:00
w0rp 477eb89793
#3332 Implement :ALERename! for ignoring errors
:ALERename! now ignores errors for files that cannot be modified, and
modifies all other files.
2020-10-15 21:56:21 +01:00
Bartek thindil Jasicki c4eb41f091 Merge remote-tracking branch 'upstream/master' 2020-10-09 12:54:48 +02:00
D. Ben Knoble 160af49450 update tests 2020-10-08 12:02:30 -04:00
D. Ben Knoble 47da7483d8 Merge remote-tracking branch 'origin/master' into fix-swipl
* origin/master:
  Add tests for maven.vim file
  Fix grammatical error in doc
  Add maven helper file; use maven wrapper if available instead of global 'mvn' executable
  fix lint, fix variable semantics and update tests
  bibclean: update matchlist reges for bibclean > v2.11.4
  Update rubocop_auto_correct_all tag
2020-10-08 11:55:39 -04:00
Andrey Popp 96ec33e6d6 Use stdin/stdout to communicate with gofmt 2020-10-03 18:44:19 +03:00
fenuks 4466c47990 Add tests for maven.vim file 2020-10-02 10:03:14 +02:00
Bartek thindil Jasicki bd1b671e82 Merge remote-tracking branch 'upstream/master' 2020-10-02 09:36:32 +02:00
D. Ben Knoble 81b92bcbfa prolog/swipl: add test for new format 2020-10-01 13:12:43 -04:00
pinicarus ac3c0c093a
feat(erlang/dialyzer): add custom options passing 2020-09-30 23:16:50 +02:00
bratekarate 56242cb874
fix lint, fix variable semantics and update tests 2020-09-26 17:09:54 +02:00
Marcus Zanona e089969404
fix(ale_linters/phpcs): add support for multiline error messages 2020-09-25 11:25:24 +02:00
Arnold Chand f8351c1b22 fix: test: mkdir should create if it doesn't exist 2020-09-17 09:58:45 -04:00
Arnold Chand 8a855e3e64 fix: tests 2020-09-17 09:35:06 -04:00
Arnold Chand fec6b63494 feat: add intelephense support for php 2020-09-17 08:06:11 -04:00
Raphael Nepomuceno 9769565f88 Collapse spaces and lines in the completion menu. 2020-09-14 12:11:16 -03:00
toastal ed47008710
addressing missing docs + cleaning up older Dhall files 2020-09-14 10:13:11 +07:00
toastal b32954a46c
Merge branch 'master' into dhall 2020-09-14 08:54:07 +07:00
Bartek thindil Jasicki 1781b1eab0 Merge remote-tracking branch 'upstream/master' 2020-09-11 10:38:36 +02:00
w0rp 08295ce174
Bump the ALE version to 3.0.0 2020-09-09 22:06:38 +01:00
w0rp 4ddf742643
Close #2522 - Check pylint on the fly
Newer versions of pylint will now check your code as you type. Older
versions will still only check the file on disk.

Co-authored-by: Oliver Wiegers <oliver.wiegers@gmail.com>
2020-09-09 21:45:15 +01:00
w0rp 78fa93bd55
Add tests for covering the coming Vint version 2020-09-09 20:34:27 +01:00
w0rp 6a367e44aa
Close #3003 - Show ignored linters in :ALEInfo 2020-09-08 22:19:13 +01:00
w0rp 7d90ff56d9
Close #3333 - Add an ALECompletePost event
Add an `ALECompletePost` event along with everything needed to make it
useful for its primary purpose: fixing code after inserting completions.

* `ALEFix` can now be called with a bang (`!`) to suppress errors.
* A new `ALELintStop` command lets you stop linting, and start it later.
2020-09-08 21:40:10 +01:00
toastal f07ecbc579
merge master -- apparently someone else added dhall? 2020-09-08 10:08:00 +07:00
w0rp c36053d4cc
Close #3268 - Implement :ALEImport
A new command, `:ALEImport`, has been added, which lets you import words
at your cursor if a completion provider can provide a completion for
that word which includes some additional text changes.
2020-09-06 22:37:37 +01:00
Dmitri Vereshchagin 49718e0ec6 Add Elvis handler for Erlang
[Elvis][1] is an Erlang style reviewer.

[1]: https://github.com/inaka/elvis
2020-09-06 12:40:28 +03:00
w0rp 5bc49d2047
Fix #3183 - Escape filename characters from LSP/tsserver 2020-09-05 21:46:39 +01:00
w0rp 152b2cb691
Clean up embertemplatelint code
Alias ember-template-lint to embertemplatelint so users can use either
string to enable the linter.
2020-09-05 19:06:07 +01:00
Bartek thindil Jasicki c78be86103 Merge remote-tracking branch 'upstream/master' 2020-09-04 13:46:11 +02:00
w0rp 844febb9fb
Fix #3322 - Apply rename changes correctly 2020-09-04 09:37:33 +01:00
Cyrille David d4a14746cd
feat(template-lint): Read from stdin (#2622)
* ember-template-lint: Lint from stdin
  * This feature has recently been implemented in ember-template-lint.
* Refactor ember-template-lint executable
* Fallback on a temporary file for old template-lint

Co-authored-by: w0rp <w0rp@users.noreply.github.com>
2020-08-31 09:26:33 +01:00
w0rp ac2100d410
Fix flake8 cd logic for invalid options 2020-08-31 09:12:36 +01:00
w0rp cdaeca452e
Add tests for \r removal 2020-08-31 09:01:44 +01:00
Konstantin Alekseev 1462de6685 Run flake8 from project root by default.
Option `per-file-ignores` was introduced in flake8 version 3.7.0.
It allows to ignore specific errors in specific files using glob syntax.
For example `per-file-ignores = src/generated/*.py:F401` will
ignore `F401` error in all python files in `src/generated`.
Thus ale has to run flake8 from project root where .flake8 config
is placed otherwise glob won't match linted file.
2020-08-30 22:56:10 +03:00
w0rp 0989da4a38
Merge pull request #3194 from maxwell-k/vint
vim/vint: show policy name
2020-08-29 20:54:09 +01:00
w0rp 6888ca46a7
Fix retrying on some test failures 2020-08-29 16:32:17 +01:00
w0rp f1ecc2e068
Fix psalm options. Retry on some test failures 2020-08-29 16:31:47 +01:00
w0rp 7e0cdb53ec
Fix #3247 - Use --always-make for make -n by default 2020-08-29 16:05:49 +01:00
Kimplul d9a7d6bc23 Improved macro handling in gcc 2020-08-29 15:17:20 +03:00
w0rp 06264c264f
typo 2020-08-29 12:35:40 +01:00
w0rp dd9ad9b5be
#3319 - Try to modify buffers later for ALEFix 2020-08-29 12:33:17 +01:00
Bartek thindil Jasicki 0de847a8e1 Merge remote-tracking branch 'upstream/master' 2020-08-29 10:42:25 +02:00
w0rp 7d4ce4e6aa
Close #3325 - Apply new formatting where possible 2020-08-28 19:50:36 +01:00
w0rp 3d5a2690ce
#3325 - ale#path#BufferCdString now generates %s:h 2020-08-28 17:46:43 +01:00
w0rp 34e409ea21
Close #3285 - lint_file is now dynamic
`lint_file` can now be computed dynamically with a callback function,
which can return a deferred result, as per `ale#command#Run`. This
allows linters to dynamically switch between checking files on disk,
or checking code on the fly.

Some tests have been fixed on Windows.
2020-08-28 14:02:05 +01:00
w0rp b8c0ac2e61
Close #3309 - Add b:ale_lint_delay 2020-08-28 09:54:43 +01:00
w0rp 47fdc02fc7
Merge pull request #2988 from joereynolds/master
Add sql-lint as linter
2020-08-28 08:43:10 +01:00
w0rp 369e3876f0
#3324 - Enable rls by default 2020-08-28 08:23:10 +01:00
Sorin Iclanzan 80bd2e18d6
Set prettier working directory to where .prettierignore is (#3101)
Prettier does not use `.prettierignore` unless the current directory is the root where the `.prettierignore` file resides.

* Update Prettier tests
* Look for prettierignore to determine project root
2020-08-28 08:14:50 +01:00
w0rp 7545b18ba1
Fix #3318 - Escape macros when parsing C flags 2020-08-27 21:17:24 +01:00
w0rp 6d843715f3
Fix C flag parsing and tests on Windows 2020-08-27 20:18:13 +01:00
w0rp af177d7825
#3318 Refactor C flag parsing to set up for quoting arguments 2020-08-27 19:33:43 +01:00
w0rp 5d3d33626c
Merge pull request #3310 from pbrisbin/master
Add dhall-format as a Fixer
2020-08-27 13:39:30 +01:00
w0rp 571cff932d
Label the test cases more clearly 2020-08-27 13:15:04 +01:00
w0rp 17605777d6
Fix #3317 - Parse -include from C flags 2020-08-27 13:05:50 +01:00
w0rp 66ff00c420
Fix #3316 - Repeat -relative for ALERepeatSelection 2020-08-27 12:41:07 +01:00
w0rp f5aa0e8457
Fix #3307 - Handle compile_commands paths better
ALE now converts paths from compile_commands.json files into absolute
paths and prefers matching against absolute file and directory names for
determining which flags to use for files. As a result, parsing
compile_commands.json to determine flags should work for a lot more C
and C++ projects.
2020-08-27 11:44:35 +01:00
w0rp a955f5dfa8
#3312 - Just check if additionalTextEdits is non-empty 2020-08-27 08:57:12 +01:00
w0rp 396fba7cca
Fix #3312 - Fix a false positive for auto imports
ALE was incorrectly detecting completion results from servers such as
rust-analyzer as wanting to add import lines when additionalTextEdits
was present, but empty.

Now ALE only filters out completion results if the autoimport setting is
off, and one of the additionalTextEdits starts on some line other than
the current line. If any additionalTextEdits happen to be identical to
the change from completion anyway, ALE will skip them.
2020-08-27 08:44:43 +01:00
patrick brisbin 447aea4af0
Add dhall-format as a Fixer
https://github.com/dhall-lang/dhall-lang
2020-08-25 09:34:34 -04:00
w0rp 3e2abe3f25
#2556 - Support modifiers for formatted filenames 2020-08-24 09:33:07 +01:00
Horacio Sanson 1a7366067a
Merge pull request #3302 from khaveesh/master
latexindent: Run fixer from stdin instead of a temporary file
2020-08-24 09:16:35 +09:00
w0rp 33eb03ea71
Yes, try again to fix Windows tests 2020-08-23 20:19:22 +01:00
w0rp d4583f1a63
Try to fix Windows tests again 2020-08-23 20:14:08 +01:00
w0rp c0566db1d2
Try to fix Windows tests 2020-08-23 20:05:09 +01:00
w0rp ba3dd0d027
Close #2556 - Support filename mapping
ALE now supports mapping files between different systems for running
linters and fixers with Docker, in virtual machines, in servers, etc.
2020-08-23 19:55:42 +01:00
Khaveesh N 76801743cf
Fixed tests 2020-08-21 17:29:43 +05:30
Bartek thindil Jasicki 62f07d820c Merge remote-tracking branch 'upstream/master' 2020-08-21 10:39:39 +02:00
w0rp 2b785688ea
#3299 Merge gcc and clang into a cc linter
Users can easily be confused when they set some options for a C or C++
compiler, and another compiler is run with different options, which
still reports errors. To remedy this, the existing `gcc` and `clang`
linters have been replaced with a `cc` linter that will run either
compiler.

This is a breaking change for ALE v3.0.0.
2020-08-20 01:49:14 +01:00
awang 4d42ebc160
Keep -iframework if present in parsed C/C++ flags (#3057)
* Keep -iframework if present in parsed C/C++ flags
* Add test to make sure -iframework is parsed

Co-authored-by: Alex Wang <ts826848@gmail.com>
2020-08-20 00:09:02 +01:00
w0rp 361027eac6
Fix #3200 - Do not use -fstack-usage from parsed flags 2020-08-19 01:04:08 +01:00
w0rp 794224aafa
#3056 Add tests for parsed C/C++ -std flag handling 2020-08-19 00:47:39 +01:00
w0rp e27d4377b5
Merge pull request #3178 from sudobash1/expand_at
Fixes #3092 - Implement loading `@file` c arguments
2020-08-19 00:15:34 +01:00
w0rp 5eda1df0a9
Remove features deprecated in previous versions 2020-08-18 23:03:43 +01:00
w0rp 4df352eee5
Fix #3294 - Fix hover off by 1, handle LSP server crashes 2020-08-18 01:48:07 +01:00
w0rp bc6304bdb0
Merge pull request #3007 from klaaspieter/swift-format
Add Apple's swift-format as a linter
2020-08-17 23:37:23 +01:00
w0rp ac56574b55
Merge pull request #3046 from hsanson/2816-fix-standard-fix-doesnt-work
Fix 2816 - Standard fix does not work.
2020-08-17 21:44:19 +01:00
w0rp 6d33417b15
Merge pull request #2759 from kgrzywacz/master
credo now recognizes umbrella projects
2020-08-17 21:34:10 +01:00
w0rp eb864730e2
Merge pull request #2906 from elebow/shelldetect-fall-back-to-filetype-if-no-hashbang
ShellDetect falls back to filetype if no hashbang (fixes #2886)
2020-08-17 21:29:16 +01:00
w0rp 514e5a8baa
Merge pull request #2940 from davidsierradz/add-markdownlint-options
allow passing custom options to markdownlint
2020-08-17 10:21:36 +01:00
blyoa d5c1d84230
Add remark-lint for a markdown fixer (#2836) 2020-08-17 10:14:38 +01:00
w0rp 5c778e1ae7
Make it easier to run tests locally
Certain tests could break if you ran them separately from other tests.
They have been patched.

`run-tests` now has a `--fast` option which runs tests with only the
fastest Vim version ALE tests with, and the custom checks.
2020-08-16 21:20:08 +01:00
Bartek thindil Jasicki 04bd84e914 Merge remote-tracking branch 'upstream/master' 2020-08-14 19:38:09 +02:00
w0rp 5a4fad6172
Fix #2899 - Handle tsserver default import completion 2020-08-14 01:55:54 +01:00
w0rp 2b2403a20d
Merge pull request #3144 from jamescdavis/dont_append_newline_when_noeol
don't append a newline to temp file when buffer is noeol and nofixeol is set
2020-08-14 00:32:28 +01:00
w0rp 8151e3e8fa
Merge pull request #2920 from ConradIrwin/prettier-standard-stdin
Fix prettier_standard to respect the configuration file
2020-08-14 00:27:41 +01:00
w0rp 94a968ef39
Merge pull request #2924 from patrick96/vlog-filename
verilog: Add filename to vlog linter output
2020-08-14 00:20:57 +01:00
toastal 167e2e7750
tests 2020-08-14 00:31:49 +07:00
Ben Boeckel 506a8532d0 rust/cargo: add support for a custom target directory
This can avoid having to wait for ALE or ALE being blocked on other
cargo actions within the same crate.
2020-08-13 10:22:33 -04:00
Horacio Sanson 8e6c7bff9a
Fix 1695 - Change rubocop fixer to use stdin (#3230)
* Fix 1695 - Change rubocop fixer to use stdin
* Update test_rubocop_fixer_callback.vader

Co-authored-by: Horacio Sanson <horacio@allm.inc>
Co-authored-by: w0rp <w0rp@users.noreply.github.com>
2020-08-13 11:25:07 +01:00
w0rp 7c4b1d8444
Close #3274 - Handle basic LSP markdown formatting 2020-08-12 22:11:45 +01:00
Nihad Abbasov d5912b53dd
Restore old behavior of ALEFix command for Rubocop (#3237)
* Restore old behavior of ALEFix command for Rubocop

Since RuboCop 0.60 ALEFix command stopped to fix all found offenses. This change restores the 
previous behavior by allowing rubocop to fix all detected offenses.

* Fix tests
* Allow to configure auto-correct option for Rubocop
2020-08-12 14:04:54 +01:00
w0rp d3f410b6f7
Fix #1608 - Treat .h as C++ files for C++ clang-tidy 2020-08-10 02:33:50 +01:00
w0rp 2237f9b462
#2919 Use compile_commands.json for headers 2020-08-10 02:14:23 +01:00
w0rp 05210846e4
Fix #3278 - Handle UTF-8 in URI encoding/decoding 2020-08-10 02:03:41 +01:00
w0rp 6d502233d8
Close #3267 - Add a general autoimport setting 2020-08-09 02:32:47 +01:00
w0rp 8bfb5c6407
Merge pull request #2849 from DonnieWest/excludeTsserverWarnings
Allow the user to remove warnings from completions
2020-08-09 01:32:27 +01:00
w0rp 2d174db5b2
Merge pull request #3107 from daliusd/tslintfix
Fix tslint fixer not working issue (temporary file not found)
2020-08-07 19:52:18 +01:00
Bartek thindil Jasicki 973c4ea053 Merge remote-tracking branch 'upstream/master' 2020-08-07 17:43:11 +02:00
w0rp f741245f11
Fix #3273 - Handle missing keys in hover information 2020-08-07 12:34:45 +01:00
w0rp 388049dbea
Try to fix gopls tests again 2020-08-07 12:30:50 +01:00
w0rp 96d525a287
Try to fix gopls tests 2020-08-07 12:27:26 +01:00
w0rp 7cefc80f1b
Fix a failing test 2020-08-07 12:21:22 +01:00
w0rp 19229e8e27
Close #2472 - Add support for pyright 2020-08-07 12:16:13 +01:00
w0rp 9bdabce8df
Fix #2907 - Handle dictionaries for capabilities 2020-08-07 10:54:38 +01:00
w0rp 667618b399
Merge pull request #3191 from mostfunkyduck/master
Fixes govet linter for go 1.13+, with tests
2020-08-07 08:54:17 +01:00
tsjordan-eng f17b74679f
fix cppcheck for 1.89+, and add column support (#3030)
* fix cppcheck for 1.89+, and add column support

In cppcheck 1.89 the output changed to be more like GCC. This commit
forces any version of cppcheck to output in that same format. This also
allows for ALE to pick up the linter's column information

* Add parameters to tests. Vader passes.

* Fix c cppcheck for v1.89
2020-08-06 20:50:44 +01:00
Andre Souto 5b3da60cea
Adds hdl_checker LSP support (#2804)
* Added hdl_checker support
* Added hdl_checker tests

HDL Checker searches for files when no config file is found, which could lead to very long searches when the user is not really on a project setting
2020-08-06 13:20:54 +01:00
w0rp 711c90c523
Merge pull request #3123 from liskin/ccls-build-dir
ccls: Detect build dir and set compilationDatabaseDirectory
2020-08-06 13:12:56 +01:00
w0rp 1bd7b3e4ad
Merge pull request #3196 from jeremija/autoimport-langserver-pr
Add autoimport and rename support for langservers
2020-08-05 13:35:48 +01:00
w0rp acf892c4d1
#1532 - Display hover information on CursorHold 2020-08-04 20:11:49 +01:00
Horacio Sanson 316c7c7372
Merge pull request #3259 from sblask/support-markdownlint-rules-with-multiple-slashes
Support markdownlint rules with multiple slashes
2020-08-01 13:22:22 +09:00
Bartek thindil Jasicki 9a9d12cf4f Merge remote-tracking branch 'upstream/master' 2020-07-31 07:56:28 +02:00
jhlink e2d1e54eb5 doc: Meaningless comment to kick CI from hang 2020-07-30 21:54:41 -04:00
Sebastian Blask fbfeae0587 Support markdownlint rules with multiple slashes 2020-07-31 11:15:13 +12:00
jhlink ac2ebafadd fix: Force add .astylerc in test_cpp_project 2020-07-30 09:58:14 -04:00
jhlink ab6aed17ab test: Find .astylerc placed with src for astyle 2020-07-30 09:43:41 -04:00
jhlink d49b06e030 fix: Find proj_options in same dir for astyle 2020-07-30 09:29:33 -04:00
Sebastian Blask 7cada95683 Support markdownlint 0.19.0 and 0.22.0
Fixes #2965
2020-07-30 09:57:46 +12:00
Horacio Sanson 5338dbf680
Merge pull request #3231 from jhlink/add-astyle-for-c-formatting
Add astyle for C/C++ formatting
2020-07-29 22:08:46 +09:00
jhlink 428c5f94da fix: Use ALE to reliably find project options 2020-07-29 01:36:45 -04:00
jhlink f4cff3bc06 test: Set empty values for astyle project_options 2020-07-28 23:29:19 -04:00
jhlink 7d40d0a16f chore: Distinguish test value name 2020-07-28 23:28:25 -04:00
jhlink a9b2f6362d chore: Delete dead test code 2020-07-28 23:26:49 -04:00
jhlink 5377272d20 fix: Change _options to _project_options 2020-07-28 19:48:27 -04:00
jhlink 0e6578cf65 fix: Remove explicit calls to file path in astyle 2020-07-26 22:05:14 -04:00
jhlink 78295024e1 feat: Add project option file support for astyle 2020-07-26 21:11:37 -04:00
jhlink b25bb64a4d feat: Use stdin/redirection for astyle 2020-07-26 20:51:41 -04:00
jhlink a9799fe90e test: Add cpp test case for astyle 2020-07-25 21:25:11 -04:00