Commit graph

2041 commits

Author SHA1 Message Date
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
Bartek thindil Jasicki
e06060a31f Merge remote-tracking branch 'upstream/master' 2020-07-24 10:38:29 +02:00
w0rp
68b484a49f
Merge pull request #2914 from hsanson/2913-fix-checkstyle-config-with-options
Fix 2913 - checkstyle config file ignored.
2020-07-21 12:49:55 +01:00
w0rp
f4668c751f
Merge pull request #3070 from hsanson/2732-add-bashate-support
Fix 2732 - Add bashate support
2020-07-21 12:47:33 +01:00
w0rp
70ab831001
Merge pull request #3119 from hsanson/2269-ktlint-stdin-support
Fix 2269 - use ktlint stdin.
2020-07-21 12:45:26 +01:00
Mark Egan-Fuller
d38b92c957 Handling for puppet parser error at end of input.
Add handling for `Syntax error at end of input` which doesn't give a
line or column.

Fixes #2656
2020-07-15 12:10:34 +01:00
Sheheryar Parvaz
23c58e63d4 Support zls language server for zig 2020-07-10 22:33:37 -04:00
jhlink
fecffeee91 test: Add astyle vader test 2020-07-10 18:26:15 -04:00
Kevin Locke
106c27644b
eslint: Use cwd from executable location to fix nested projects (#3222)
* Split FindNearestExecutable from FindExecutable

The path searching in ale#node#FindExecutable() will be useful for
eslint.  Refactor it into a separate function so it can be used without
regard for the state of the _use_global and _executable variables.

Signed-off-by: Kevin Locke <kevin@kevinlocke.name>

* eslint: Set project root from local executable

Using the nearest directory with node_modules does not work correctly
for nested projects where the eslint dependencies are in the outer
project.  For example:
https://github.com/dense-analysis/ale/issues/3143#issuecomment-652452362

Adopt the behavior of SublimeLinter, which runs from project_root
determined by the presence of the eslint executable in node_modules/.bin
(or eslint in dependencies/devDependencies of package.json, which we can
add later as necessary).  See [NodeLinter#find_local_executable].

[NodeLinter#find_local_executable]: https://github.com/SublimeLinter/SublimeLinter/blob/056e6f6/lint/base_linter/node_linter.py#L109

Signed-off-by: Kevin Locke <kevin@kevinlocke.name>
2020-07-08 14:42:01 +01:00
Christopher Peterson
1fcb9d1e1a Tests/puppet: add new test case for a heretofore unaccounted-for version of error message 2020-07-02 12:44:39 -04:00
Bartek thindil Jasicki
0f45d3d01d Merge remote-tracking branch 'upstream/master' 2020-07-02 10:11:30 +02:00
Kevin Locke
b3c6db173a
Run ESLint fixer from project root, where possible (#3096)
* Split eslint#GetCdString from eslint#GetCommand

Move the code for finding the project root and building the cd string
into a separate function so that it can be reused in the eslint fixer.

Signed-off-by: Kevin Locke <kevin@kevinlocke.name>

* Run ESLint fixer from project root dir

To match the ESLint linter, as changed in 9ee57d43 (which I forgot to
apply to the fixer, whoops).

Fixes: #3094
Closes: #3095

Signed-off-by: Kevin Locke <kevin@kevinlocke.name>
2020-07-01 17:00:21 +01:00
Horacio Sanson
834d6f9c48
Merge pull request #3158 from ulidtko/improve-dockerfile_lint
Improve :ALEDetail for dockerfile_lint [READY TO REVIEW]
2020-06-20 20:58:42 +09:00
w0rp
1428c7b29e
Update the internal ALE version to 2.7.0 2020-06-11 19:21:17 +01:00
Bartek thindil Jasicki
a5e7f2c8bb Merge remote-tracking branch 'upstream/master' 2020-06-07 09:26:06 +02:00
Jerko Steiner
b29e9867e8 Add test for LSP autoimport 2020-05-31 11:46:10 +02:00
Jerko Steiner
b339a8bfa0 Add support for rename (documentChanges) 2020-05-31 11:00:53 +02:00
Keith Maxwell
53bfe41841 vim/vint: show policy name
So that I can find the relevant information in the vint
linting policy summary and policies can be easily configured
https://github.com/Vimjas/vint/wiki/Vint-linting-policy-summary

Before this change an example warning message appears as:

    autocmd should execute in an augroup or execute with a group (see :help :autocmd)

After this change the same example appears as:

    ProhibitAutocmdWithNoGroup - autocmd should execute in an augroup or execute with a group (see :help :autocmd)
2020-05-30 08:38:07 +01:00
mostfunkyduck
35c7c297b6 Fixes govet linter for go 1.13+, with tests 2020-05-25 11:46:16 -04:00
Paco
7265ceb6d0
Support revive for go files (#2933)
Signed-off-by: Penghui Liao <liaoishere@gmail.com>
2020-05-22 06:09:14 -05:00
Stephen Robinson
b209315714 Fixes #3092 - Implement loading @file c arguments 2020-05-20 18:15:52 -07:00
NiBo
e61e1147b0 refactor(javac): ale_java_javac_classpath variable supports String and List types 2020-05-19 10:43:16 +08:00
NiBo
ff6bfc3d37 refactor(javac): ale_java_javac_sourcepath variable supports String and List types 2020-05-19 10:41:35 +08:00
Horacio Sanson
69d96aa9d9
Merge pull request #3077 from puritys/javaagent
To support javaagent on eclipselsp
2020-05-15 10:12:25 +09:00
Horacio Sanson
c2b01f0e28
Merge pull request #3134 from Ian2020/master
Add shellcheck as linter for bats files
2020-05-09 11:24:55 +09:00
Ian2020
ca97f32258 Use a function to define shellcheck linters and vars needed, fixes tests 2020-05-08 12:55:54 +01:00
max ulidtko
c0d74b8094 Fix style and test 2020-05-06 14:05:39 +03:00
RyanSquared
70005134e5
Merge branch 'rust-analyzer' of https://github.com/jonhoo/ale into jonhoo-rust-analyzer 2020-05-05 09:21:49 -05:00
James C. Davis
15d590ee5e
fix: don't append newline when buffer is noeol and nofixeol 2020-04-30 15:00:10 -04:00
Ian2020
65bea1a5cb Main logic of shellcheck has moved, updated backward compat test 2020-04-29 17:45:16 +01:00
Klaas Pieter Annema
2548763d04
Add Apple's swift-format as a linter 2020-04-29 14:33:13 +02:00
Ian2020
f67cb56e5e Fix shell detection test, shellcheck function name has changed 2020-04-28 18:20:10 +01:00
Ian2020
3f34265151 Fix handler test, function name has changed 2020-04-28 18:13:34 +01:00
Jeffrey Lau
60d683da3b Add vim-language-server linter support 2020-04-21 02:29:22 +08:00
Oliver Ford
36b50058bb
Add terraform-lsp integration (#2758)
* Add terraform-lsp integration

https://github.com/juliosueiras/terraform-lsp

* Add tests & docs for terraform-lsp integration

terraform_langserver_options setting added to send custom flags to
terraform-lsp.

Vader tests have been added to test custom executable, custom flags, and
finding the project root. All tests pass.

Initial documentation has been added for the above.

Resolves dense-analysis/ale#2758, juliosueiras#57

* Fix tag alignment

Co-authored-by: = <Aubrey.S.Lavigne@gmail.com>
Co-authored-by: w0rp <w0rp@users.noreply.github.com>
2020-04-20 16:02:31 +01:00
Tomas Janousek
4fbfcc9dec ccls: Detect build dir and set compilationDatabaseDirectory
Fixes #2621
2020-04-18 13:57:57 +02:00
w0rp
64b9a2708d
Merge pull request #3098 from tarikgraba/verilator-columnn
Adds column number to the verilator verilog linter
2020-04-18 12:36:16 +01:00
w0rp
1f9ac1c6dc
Fix the cursor tests, that stop tests running 2020-04-18 12:26:38 +01:00
Yuto
93a13d7353
Broken message in pycodestyle (or any other Linters whose name include 'code') (#3114)
* Swap substitution order for echoed message

This prevents 'code' string in liter_name to be substituted by accident.
Linters including pycodestyle have been affected by this problem.

* Add test for linter whose name contains 'code'

Test for c525db8cb4088d02448c5ddcf4a80ffa028c3181
2020-04-18 11:59:26 +01:00
TG
00eee550ea Adds column number to the verilator verilog linter
Since version 4.032 (04/2020) verilator linter messages also contain the
column number, and look like:

%Error: /tmp/test.sv:3:1: syntax error, unexpected endmodule, expecting ';'

To stay compatible with old versions of the tool, the column number is
optional in the researched pattern regular expression.

See commit:
81c659957e
2020-04-18 09:57:01 +02:00
Horacio Sanson
5035281cb9 Fix 2269 - use ktlint stdin.
Use stdin flag instead of temporary files. This allows ktlint to work
with .editorconfig files.
2020-04-18 15:27:11 +09:00
w0rp
dc054f30c8
Merge pull request #2823 from jeremija/do-not-save-on-autoimport
Do not save after ALERename and ALEOrganizeImports
2020-04-17 17:32:36 +01:00
Horacio Sanson
16cd59805b
Merge pull request #3050 from StarryLeo/fix-vim-sign-priority-patch-check
Fix vim sign priority patch check
2020-04-17 22:22:03 +09:00
w0rp
82f734a7c2
Closes #3019 - Implement default navigation
Default navigation for commands that jump to new locations has been
implemented with the `ale_default_navigation` variable, and all commands
that jump to locations now support `-tab`, `-split`, or `-vsplit`
arguments for overriding the default navigation behavior.
2020-04-15 16:50:13 +01:00
Dalius Dobravolskas
891852de71
Fix tslint fixer not working issue (temporary file not found) 2020-04-15 17:30:19 +03:00
Jon Gjengset
6087765cad
Move to rust-analyzer everywhere 2020-04-09 13:23:03 -04:00
puritys
fa19bca80e To support javaagent on eclipselsp 2020-03-26 06:40:07 +00:00
Horacio Sanson
7b9855f1fe Fix 2732 - Add bashate support 2020-03-23 12:18:35 +09:00
StarryLeo
302ce71931 Fix vim sign priority patch check
With Vim 8.2 released, the previous check method is not accurate enough.
2020-03-15 14:58:38 +08:00
Horacio Sanson
c207d6a550 Fix 2816 - Standard fix does not work.
The standard linter --fix fails if the file being input is not relative
to the project root (https://github.com/standard/standard/issues/1384).

This MR attempts to fix this by changing the command so the input file
is relative to the project root and the output is to a temporary file.

Preliminary tests with toy javascript projects seem to indicate this
works fine.
2020-03-12 16:29:46 +09:00
w0rp
bbe5153fcb
Fixes #2982 - Implement g:ale_exclude_highlights
Particular highlights can now be excluded by providing Lists of regular
expressions.
2020-03-11 12:52:41 -04:00
Joe Reynolds
07080066e4 Add sql-lint as linter 2020-01-31 11:11:12 +00:00
Harry Percival
72d2c55479 Mypy: try to find folder containing mypy.ini to use as cwd. (#2385)
* When deciding which directory to run mypy from, prefer a folder with mypy.ini in it
* Add a test for mypy.ini-finding behaviour
2020-01-02 14:35:21 +00:00
w0rp
57eba1afac
Fix the build 2020-01-02 14:23:28 +00:00
w0rp
8c4c8dfd97
Fix #2704 - Show mypy notes; can be disabled 2020-01-02 14:19:21 +00:00
Jerko Steiner
0cb432cb82 Add TypeScript autoimport support for deoplete (#2779)
* Add autoimport support for deoplete

* Fix test_deoplete_source.py

* Use callback instead of is_async for deoplete

Shuogo, the author of Deoplete, does not recommend using the `is_async`
option:

> I think is_async is not recommended. It is not so useful and broken.
> You should use callback system instead.

Link: https://github.com/Shougo/deoplete.nvim/issues/1006#issuecomment-526797857

Incidentally, the same thread mentiones an issue started by w0rp:
https://github.com/Shougo/deoplete.nvim/issues/976

The deoplete docs also say is_async is deprecated:

> is_async        (Bool)
>     If the gather is asynchronous, the source must set
>     it to "True". A typical strategy for an asynchronous
>     gather_candidates method to use this flag is to
>     set is_async flag to True while results are being
>     produced in the background (optionally, returning them
>     as they become ready). Once background processing
>     has completed, is_async flag should be set to False
>     indicating that this is the last portion of the
>     candidates.
>
>     Note: The feature is deprecated and not recommended.
>     You should use callback system by
>     |deoplete#auto_complete()| instead.

Link: https://github.com/Shougo/deoplete.nvim/blob/master/doc/deoplete.txt

Co-authored-by: w0rp <w0rp@users.noreply.github.com>
2020-01-01 19:00:41 +00:00
davidsierradz
0cea55924b allow passing custom options to markdownlint 2019-12-19 13:11:25 -05:00
Kevin Locke
9ee57d4362 Run ESLint from project root dir where possible
ESLint 6 loads all plugins/configs/parsers relative to the project root
which, by default, is the directory in which ESLint is invoked, as
described in [ESLint RFC 2018-simplified-package-loading].

Therefore, ALE should run ESLint from the project root, when possible,
so that dependencies will load.  This commit does so.

[ESLint RFC 2018-simplified-package-loading]: https://github.com/eslint/rfcs/blob/master/designs/2018-simplified-package-loading/README.md

Fixes: #2787

Signed-off-by: Kevin Locke <kevin@kevinlocke.name>
2019-12-17 12:25:44 -07:00
patrick96
1e9f870b74
verilog: Add filename to vlog linter output 2019-12-05 19:35:34 +01:00
Conrad Irwin
efe120ce9a Fix prettier_standard to respect the configuration file
Before this change, prettier_standard would run and ignore any
.prettierrc, now it will respect the configuration of the file being
linted.

This change relies on prettier-standard 16.1.0 for the --stdin-filepath
flag, but is backward compatible: older versions of prettier-standard
will ignore the unknown flag and continue to run with no configuration
file.
2019-12-04 23:15:41 -08:00
Horacio Sanson
8fbcba0091 Fix 2913 - checkstyle config file ignored.
If checkstyle is configured with custom options that contain "-c" then
the checkstyle config file option is ignored. This PR modifies the
regular expression when creating the checkstyle command to avoid this.
2019-11-27 23:19:44 +09:00
Horacio Sanson
5f95d032ee Fix 2891 - eslint not showing errors.
ESLint errors are contained in an array that can contain different
stuff other than JSON error messages. This patch iterates over the whole
array ignoring any non-json data.
2019-11-26 13:37:25 +09:00
Eddie Lebow
1997a8f7e2
ShellDetect: fall back to filetype if no hashbang
Some files lack a hashbang line but still have an unambiguous filetype.
For example, the file `.zshrc` has the filetype `zsh`.

Augment ale#handlers#sh#GetShellType to fall back to the filetype if
no hashbang line can be found.
2019-11-23 00:34:40 -05:00
w0rp
b91d82bfaa
Merge pull request #2847 from DonnieWest/allowUserToCustomizeItems
Allow user to customize items
2019-11-15 09:34:24 +00:00
w0rp
9005a62dc2
Clean up the nimpretty code 2019-11-14 14:50:21 +00:00
w0rp
7665559d0e
Merge pull request #2660 from YPCrumble/master
Add StandardJS linter for TypeScript
2019-11-14 14:47:19 +00:00
Bùi Thành Nhân
abad8e474b add nimpretty fixer 2019-11-09 16:28:49 +07:00