Open aktau opened 4 years ago
Okay, please send pull-request.
I'll likely only have time for something small. But also: any thoughts on the last paragraph?
There are not any meaning about that current README.md does not have lint-stdin in shellcheck section. So Iet's change it to use.
Hi! My use case is running shellcheck(1) with efm-langserver (using the nvim-lsp client). I noticed that after I made a change to my document the returned diagnostics did not match the new content, but the old one (reference: https://github.com/nvim-lua/diagnostic-nvim/issues/40).
The reason is: nvim-lsp sends a
textDocument/didChange
whenever the user makes a change. This does not mean that the document is saved.My configuration is essentially copied from the README:
I traced the shellcheck invocation made by
efm-langserver
before and after the edit of a shell file:Reading the code I also noticed that
f.Text
is only used when stdin is false. This means that I'd need to use shellcheck in stdin mode to get this to work. A couple of notes:-
)./dev/stdin
instead of the filename for all tools on *nix operating systems. Or to create a temporary file (some tools may require a seekable file, or for Windows this may be necessary).