Converting a commandline on the fly...

15 views
Skip to first unread message

tu...@posteo.de

unread,
Dec 4, 2020, 1:34:09 AM12/4/20
to vim...@googlegroups.com
Hi,

sorry...the subject is somehow weird...

When compiling things containing error the compiler spits out
someting like:

ERROR: Using Freedom() before declaration. File ../source/People.c:12:5

where 12 is the line number and 5 the olumn where the error is
detected by the compiler.

Vim would understand a commandline like this
vim ../source/People.c +12

Is there any way to convert a commandline (created by cut'n'paste in
the terminal)

vim ../source/People.c:12:5

inside vim that way, that vim interpretes the :12 as a line number and
:5 as column number that way that it is no longer needed to reedit
the commandline given above after cut'n'paste?

Cheers!
Meino


Salman Halim

unread,
Dec 4, 2020, 8:48:14 AM12/4/20
to Vim Users
Look up the errorformat option. You can specify the format in which the compiler returns messages so Vim can understand it. 

--

Salman

--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/vim_use/20201204063358.paecuwjb42g7h6oy%40solfire.

Gary Johnson

unread,
Dec 4, 2020, 1:32:55 PM12/4/20
to vim...@googlegroups.com
Try the vim-fetch plugin, from either of these sites:

https://www.vim.org/scripts/script.php?script_id=5089
https://github.com/wsdjeg/vim-fetch

Note that the VimBall archive seems not to have been built properly,
so you may have to move some of the installed files around.

Regards,
Gary

Reply all
Reply to author
Forward
0 new messages