Commit Graph

168 Commits

Author SHA1 Message Date
Felix Maurer e81f005c78
Fix end line number when it exceeds the file (#4130)
If the end of the error exceeds the file, set it to the last line,
similarly as it is done with the beginning of the error.
2022-04-01 17:13:27 +09:00
w0rp 9fe7b1fe6a
Close #2281 - Separate cwd commands from commands
Working directories are now set seperately from the commands so they
can later be swapped out when running linters over projects is
supported, and also better support filename mapping for running linters
on other machines in future.
2021-03-01 20:11:10 +00: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 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
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 6874120405
Fix #3323 - Set default for g:ale_filename_mappings 2020-08-28 09:33: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
w0rp 5eda1df0a9
Remove features deprecated in previous versions 2020-08-18 23:03:43 +01:00
w0rp 381fe1badf
Close #829 - Close LSP documents when buffers are deleted 2019-05-14 00:21:58 +01:00
w0rp fcc2c3ba71
Fix #2415 - Mark tsserver and LSP linters inactive again 2019-04-17 18:12:50 +01:00
w0rp ce64e349cd
Close #2132 - Add deprecation warnings for old features 2019-04-07 16:24:08 +01:00
w0rp ffa45fa3fb
#2132 - Implement deferred command handling for linters 2019-02-21 21:24:41 +00:00
w0rp 7487ecb957
Simplify code for marking linters as active 2019-02-14 10:10:46 +00:00
w0rp 3050a132b5
Remove ProcessChain code we do not need now 2019-02-13 17:56:10 +00:00
w0rp 21a8b9f1e3
Make it easier to remove command_chain support later 2019-02-13 17:53:01 +00:00
w0rp 926ad47a49
#2132 - Implement deferred executable string handling for linters 2019-02-12 18:05:33 +00:00
w0rp b32fdfe816
#2132 Implement deferred objects for ale#command#Run 2019-02-08 08:41:38 +00:00
w0rp 81c73da3b9
#2132 - lint and fix with ale#command#Run
A new function is added here which will later be modified for public use
in linter and fixer callbacks. All linting and fixing now goes through
this new function, to prove that it works in all cases.
2019-02-06 22:00:11 +00:00
w0rp cf14d0aa53
#2132 Unify temporary file management in command.vim 2019-01-26 19:33:52 +00:00
w0rp c0b2090fbb
#2132 Move CreateTemporaryFileForJob calls into FormatCommand 2019-01-12 18:34:26 +00:00
w0rp 6644563949
#2132 Remove the need for the hidden add_newline option by tweaking the flow command 2019-01-12 13:14:29 +00:00
Luan Santos f58a5cba05
Move virtualtext handling to own file
This allows cursor and virtualtext to be independently autoloaded.
2018-11-06 22:31:35 -08:00
Luan Santos c41dbe2ba9
Add support for nvim's virtualtext on cursor
- Add g:ale_virtualtext_cursor boolean to enable/disable it
- Add g:ale_virtualtext_prefix to configure what prefix to use (default:
'> ')
- Requires neovim 0.3.2's unreleased API `nvim_buf_set_virtual_text`
2018-11-05 22:45:40 -08:00
w0rp caac5c93d6
#2017 Add support for display results from other sources 2018-10-29 18:28:28 +00:00
Felipe Sere fba4cfeae9 To avoid blocking build tools, suspend ALE when suspending vim 2018-09-16 15:57:13 +01:00
w0rp d476578a40
Improve ALE project style checking
* The project style linter now runs while you type.
* Now the scripts for checking the project require blank lines.
* Many style issues have been found and fixed.
2018-09-04 16:51:18 +01:00
w0rp 06132954b1
Switch to v:t_ variables for type checks 2018-07-25 01:27:28 +01:00
w0rp a42999a639
Massively reduce the amount of code needed for linter tests 2018-07-15 18:28:28 +01:00
w0rp a782e06223
Handle linter callback functions being unknown or deleted 2018-07-13 09:47:26 +01:00
w0rp ac0abc7c1f
Fix #1716 - Replace tempdir() with a wrapper to preserve TMPDIR 2018-07-12 13:05:59 +01:00
w0rp da692b2e2d
Support formatting escaped executable names into commands with %e 2018-07-05 20:56:31 +01:00
w0rp db85b931ec
Remove deprecated code for the 2.0 release 2018-07-04 08:36:34 +01:00
w0rp 82ea36576c
Move ClockMilliseconds to events, so fewer files are loaded some times 2018-06-19 20:53:49 +01:00
w0rp bda89506ba
Lazy-load LSP linters, and check b:changedtick before notifying about changes 2018-06-15 10:01:28 +01:00
w0rp c0a279f967
Indicate things to be removed in version 2.0 2018-05-28 19:39:49 +01:00
w0rp f2837b5802
#1524 - Define global variables where they are needed 2018-05-28 19:19:20 +01:00
w0rp 18509195f5
#1524 Do not try to check buffers with empty filetypes 2018-05-28 17:38:14 +01:00
w0rp d9717147bf
Close #1559 - Report errors from LSP servers in :ALEInfo 2018-05-28 16:24:15 +01:00
Chris Marchesi b7996803c9
Add ALEJobStarted User autocommand event
The ALELintPre and ALELintPost autocommand events are currently being
used by lightline-ale to refresh the status line and check the linter
status for a current buffer. One of the plugin's checks looks to see if
linters are currently running, via ale#engine#IsCheckingBuffer(). This
currently only works partially in certain situations. In my particular
case, working with Go files, this only seems to function properly when a
file is initially opened. Saving a file does not correctly update the
status.

This seems to be due to the fact that ALELintPre actually runs before
any jobs are carried out, making it plausible that hooking into
ALELintPre for the purpose of checking to see if there are any currently
running linters for a buffer is unreliable as it would be prone to
pretty obvious race conditions.

This adds a new User autocommand, ALEJobStarted, that gets fired at the
start of every new job that is successfully run. This allows a better
point to hook into checking the linter status of a buffer using
ale#engine#IsCheckingBuffer() by ensuring that at least one job has
started by the time IsCheckingBuffer is run.
2018-04-27 15:40:02 -07:00
w0rp 91d7e81ebc
Fix #605 - Support `vcol: 1` for multi-byte character positions 2018-04-08 17:17:46 +01:00
w0rp 43e8f47e6e
#1431 Normalize paths when checking for temporary paths on Windows 2018-03-18 20:39:50 +00:00
w0rp 0a0535546f Add a command for stopping all LSP clients 2018-03-06 10:23:55 +00:00
w0rp 08cfd5f90c
Close #1379 - Increment b:ale_linted when a buffer is checked 2018-03-03 16:22:56 +00:00
w0rp 2096562899 Make updating linter results slightly faster when the list is empty 2018-03-02 12:10:27 +00:00
w0rp 478a2883a6 #1363 Make ale#engine#IsCheckingBuffer part of the public API 2018-02-25 12:57:54 +00:00
w0rp a5ec4143d2 Fix the didSave tests so they work in NeoVim 0.1.7, and do not send the message for tsserver 2018-01-19 16:50:04 +00:00
Rafael Lerm 042dec059a Send didSave message to LSP-based linters (#1295)
* Also send didSave to LSP linters.
* Add tests for messages sent to LSP linters.
2018-01-19 16:40:55 +00:00
w0rp e43e7065da Fix #1115 - Add support for wrapping all commands with an option 2017-12-20 12:20:38 +00:00
w0rp 8afd9a70a6 #1212 Fix some echo cursor flashing by only echoing once all linters are finished. 2017-12-18 11:14:10 +00:00
Martin Tournoij 4825cce1cc
Run before lint cycle, rename autocmds 2017-12-10 13:10:52 +00:00