Skip to main content
added 115 characters in body
Source Link
Julian
  • 909
  • 5
  • 5

There isn't a way, and I think a script is the only way. The reason being, what if you had a file called setup.cfg:11 and wanted to edit it?

Here is a quick script that does what you want as a oneliner...

editline() { vim ${1%%:*} +${1##*:}; }

There isn't a way, and I think a script is the only way. The reason being, what if you had a file called setup.cfg:11 and wanted to edit it?

There isn't a way, and I think a script is the only way. The reason being, what if you had a file called setup.cfg:11 and wanted to edit it?

Here is a quick script that does what you want as a oneliner...

editline() { vim ${1%%:*} +${1##*:}; }
Source Link
Julian
  • 909
  • 5
  • 5

There isn't a way, and I think a script is the only way. The reason being, what if you had a file called setup.cfg:11 and wanted to edit it?