errorformat

How to write multiline errorformat string?

不想你离开。 提交于 2019-12-11 08:43:00
问题 I want to write OpenCL syntax checker for vim-opencl plugin. OpenCL compiler do some strange formatting of output errors. There are two types of errors. Normal (with small error explanation): "/tmp/OCLUKvOsF.cl", line 143: error: expression must have integral type rec_table[PRIME_P - ri] = PRIME_P - i; ^ And not-normal with line-break in error explanation: "/tmp/OCLUKvOsF.cl", line 148: error: a value of type "uint16" cannot be used to initialize an entity of type "uint" uint a = value, b =

Vim errorformat and jslint

痞子三分冷 提交于 2019-12-09 18:31:57
问题 I am trying to get makeprg and errorformat working with VIM and jslint, and can't seem to get the error format right for the life of me... I am using the nodejs version of jslint which produces results like: 1 116,9: The body of a for in should be wrapped in an if statement to filter unwanted properties from the prototype. for (var k in o) I basically want to match the line number, and column and the error and use the current file for the filename. Anyone know how to do this? To be clear, I

What's the meaning of some advanced patterns in vim errorformat? (%s, %+, %\\@=)

扶醉桌前 提交于 2019-12-09 16:36:10
问题 I tried reading :help errorformat and googling (mostly stackoverflow), but can't understand some of the patterns mentioned there: %s - "specifies the text to search for to locate the error line. [...]" um, first of all, trying to understand the sentence at all, where do I put the "text to search", after the %s ? before it? or, I don't know, does it maybe taint the whole pattern? WTF? secondly, what does this pattern actually do, how does it differ from regular text in a pattern, like some

How to put cscope output in Vim quickfix window?

安稳与你 提交于 2019-12-08 17:38:09
问题 I want to redirect output from cscope to Vim quickfix window. The glue part is easy enough, but I currently stuck at errorformat. Here's an example from cscope output (cscope -L -1 bar): Format: "filename scope linenumber sourceline" Example: "abc.cpp foo 25 bar()" This means inside foo(), at line 25 in abc.cpp there is a call to bar(). efm = %f\ %*[^\ ]\ %l\ %m works but the scope information is lost. For example: Input: "abc.cpp foo 25 bar()" becomes Output: "abc.cpp |25| bar()" What I want

How to use quickfix in Vim to debug Bash scripts

江枫思渺然 提交于 2019-12-04 11:00:42
问题 I use Vim every day to write shell scripts. I have been reading about the quickfix window, and I think it could speed up my productivity in the edit-run-fix cycle. If I understood properly, I have to write my own errorformat function in order to Vim to be able to catch the errors and introduce them into the quickfix window. But this seems to be really complicated. Is there an easier/more convenient way to take advantage of the quickfix window in Vim when writing Bash scripts? 回答1: Vim's

Vim errorformat and jslint

你说的曾经没有我的故事 提交于 2019-12-04 07:37:18
I am trying to get makeprg and errorformat working with VIM and jslint, and can't seem to get the error format right for the life of me... I am using the nodejs version of jslint which produces results like: 1 116,9: The body of a for in should be wrapped in an if statement to filter unwanted properties from the prototype. for (var k in o) I basically want to match the line number, and column and the error and use the current file for the filename. Anyone know how to do this? To be clear, I am looking for the errorformat to get this command working. Currently my .vimrc file has augroup js set

What's the meaning of some advanced patterns in vim errorformat? (%s, %+, %\\\\@=)

爱⌒轻易说出口 提交于 2019-12-04 04:28:55
I tried reading :help errorformat and googling (mostly stackoverflow), but can't understand some of the patterns mentioned there: %s - "specifies the text to search for to locate the error line. [...]" um, first of all, trying to understand the sentence at all, where do I put the "text to search", after the %s ? before it? or, I don't know, does it maybe taint the whole pattern? WTF? secondly, what does this pattern actually do, how does it differ from regular text in a pattern, like some kinda set efm+=,foobar ? the "foobar" here is for me also "text to search for"... :/ %+ - e.g. I I've seen

How to use quickfix in Vim to debug Bash scripts

痴心易碎 提交于 2019-12-03 06:43:42
I use Vim every day to write shell scripts. I have been reading about the quickfix window, and I think it could speed up my productivity in the edit-run-fix cycle. If I understood properly, I have to write my own errorformat function in order to Vim to be able to catch the errors and introduce them into the quickfix window. But this seems to be really complicated. Is there an easier/more convenient way to take advantage of the quickfix window in Vim when writing Bash scripts? Vim's quickfix window is designed to speed up the edit-compile-edit cycle. Since Bash scripts do not get compiled, we

Vim errorformat for Visual Studio

杀马特。学长 韩版系。学妹 提交于 2019-12-03 02:42:36
问题 I want to use Vim's quickfix features with the output from Visual Studio's devenv build process or msbuild. I've created a batch file called build.bat which executes the devenv build like this: devenv MySln.sln /Build Debug In vim I've pointed the :make command to that batch file: :set makeprg=build.bat When I now run :make, the build executes successfully, however the errors don't get parsed out. So if I run :cl or :cn I just end up seeing all the output from devenv /Build. I should see only

Vim errorformat for Visual Studio

点点圈 提交于 2019-12-02 16:15:31
I want to use Vim's quickfix features with the output from Visual Studio's devenv build process or msbuild. I've created a batch file called build.bat which executes the devenv build like this: devenv MySln.sln /Build Debug In vim I've pointed the :make command to that batch file: :set makeprg=build.bat When I now run :make, the build executes successfully, however the errors don't get parsed out. So if I run :cl or :cn I just end up seeing all the output from devenv /Build. I should see only the errors. I've tried a number of different errorformat settings that I've found on various sites