Skip to content

Instantly share code, notes, and snippets.

@thinca
Created June 18, 2012 15:26
Show Gist options
  • Select an option

  • Save thinca/2948905 to your computer and use it in GitHub Desktop.

Select an option

Save thinca/2948905 to your computer and use it in GitHub Desktop.
nnoremap <silent> <buffer> dd :call <SID>del_entry()<CR>
nnoremap <silent> <buffer> x :call <SID>del_entry()<CR>
vnoremap <silent> <buffer> d :call <SID>del_entry()<CR>
vnoremap <silent> <buffer> x :call <SID>del_entry()<CR>
if exists('*s:del_entry')
finish
endif
function! s:del_entry() range
let qf = getqflist()
unlet! qf[a:firstline - 1 : a:lastline - 1]
call setqflist(qf, 'r')
execute a:firstline
endfunction
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment