Tuesday, November 3, 2020

delete from- to

I found a site 'vi/vim delete commands and examples' which has a great
explanation on how using variants of the delete command.

But what if you use relative line numbering in Vim?

':+13,$d'

This deletes from 13 lines below to the end of the file

Pointing to a line can be made relative by using a '+' (didn't try a '-'
but it should also work).

Awesome!

https://alvinalexander.com/linux/vi-vim-d

//meine

--
--
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+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/vim_use/20201103194857.GB1135%40trackstand.

No comments: