Ziceai ca linux e nasol la capitolul comenzi? (txt)

  1. /^\n\{3} : find 3 empty lines

  2. /\(^str.*\n\)\{2} : find 2 successive lines starting with str

  3. :vmap // y/<C-R>"<CR> : search for visually highlighted text

  4. :%s/^.\{-}pdf/new.pdf/ : delete to 1st pdf only

  5. :%s/\d\+/\=(submatch(0)-3)/ : decrement numbers by 3

  6. :g/loc\|function/s/\d/\=submatch(0)+6/ : increment numbers by 6 on certain lines only

  7. :%s,\(all/.*\)\@<=/,_,g : replace all / with _ AFTER "all/"

  8. :g/^\s*$/d : delete all blank lines

  9. :redir @*|sil exec 'g#<\(input\|select\|textarea\|/\=form\)\>#p'|redir END : filter all form elements into paste register

  10. :g/^$/,/./-j : compress empty lines

  11. :g/\(^I[^^I]*\)\{80}/d : delete all lines containing at least 80 tabs

  12. :nmap <leader>c :hi Normal guibg=#<c-r>=expand("<cword>")<cr><cr> : display RGB colour under the cursor eg #445588

  13. :'a,'b!sort -u : use an external program to filter content

  14. :%s#\<from\>\|\<where\>\|\<left join\>\|\<\inner join\>#\r&#g : format a mysql query
 Prima pagina |  Adaugat de ddumi (250 vizualizari) |  Text format (download) |  Sursa cod/script