Lint error info dialog contains unwanted characters #1072

alexanderjeurissen opened this Issue Dec 26, 2016 · 6 comments


None yet

3 participants


I'm not sure if this is a fault of my configuration but when Kakoune shows the info dialog for a lint warning then unwanted text is prepended:

lint output

app/controllers/test_controller.rb:5:3: error: Assignment Branch Condition size for genii is too high. [17.52/15]

screenshot of the info dialog:
screen shot 2016-12-26 at 17 48 06

expected behaviour:
The info dialog should only show the lint error message and kind, not prepend the line number and column.


error: Assignment Branch Condition size for genii is too high. [17.52/15]
lenormf commented Dec 27, 2016

What's your version and implementation of awk?


@lenormf I tried both the awk that was supplied with OSX and the one available on Homebrew.

$ /usr/bin/awk --version
awk version 20070501

$ which awk

$ awk --version
awk version 20121220

both the versions listed above result in the behaviour that is shown in the screenshot.

Here is the code of the binstub I'm using as lintcmd:

#!/usr/bin/env bash
rubocop --format emacs "$1" | sed -e s'/[WCE]\:/error\:/' -e s'/F\:/fatal\:/'
mawww commented Jan 2, 2017

Hum, here it seems lint is emitting two errors on the same line, and lint.kak shows both of them, which looks like a correct behaviour.

Do you mean that Method has too many lines is not an error emitted by your linter ?

lenormf commented Jan 8, 2017

I think the 5,3,error prefix isn't correct.

mawww commented Jan 8, 2017

Ahhh, yeah right, sorry, then it would seem that the sed replace s/^[[:digit:]]\+,[[:digit:]]\+,//g; s/'/\\\\'/g; p; in rc/base/lint.kak:64 is failing for some reason.

lenormf commented Jan 8, 2017

\+ is supported by extended regex only, the BSD (default on mac) implementation of sed probably expects the basic syntax? It would be weird that mac users haven't had this issue earlier, if it's a regex grammar error.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment