Search code examples
vimfilenamesline-numbers

Is there a way to make vim recognize line numbers at end of filenames?


I work almost exclusively in the terminal, and very often I need to view files that appear in error stacktraces. A very common format is /some/file:99, where 99 is the line number. I'd like to be able to copy that line, and open goto that line easily in vim.

What I'm looking for is the ability to do :e /some/file:99, and vim automatically opens that file at line 99. Does something like this exist? If not, is it possible to write a plugin for it?


Solution

  • This plugin was designed with this specific purpose in mind: file:line