Skip to content

Instantly share code, notes, and snippets.

@wongjiahau
Last active August 13, 2017 12:24

Revisions

  1. wongjiahau revised this gist Aug 13, 2017. 1 changed file with 1 addition and 0 deletions.
    1 change: 1 addition & 0 deletions Vim mnemonics and keys
    Original file line number Diff line number Diff line change
    @@ -12,6 +12,7 @@ cw //Change small word (until any non-alphabet is reached)
    % //Go to next matching parenthesis
    `` //Snap back to where % has jumped from
    v/}<ENTER> //Select until the character }
    :noh //Clear highlighted words


    IF Surround.vim is enabled
  2. wongjiahau revised this gist Aug 12, 2017. 1 changed file with 1 addition and 0 deletions.
    1 change: 1 addition & 0 deletions Vim mnemonics and keys
    Original file line number Diff line number Diff line change
    @@ -11,6 +11,7 @@ cw //Change small word (until any non-alphabet is reached)
    180<Ctrl-x> //Xubtract the first number in the current line by 180
    % //Go to next matching parenthesis
    `` //Snap back to where % has jumped from
    v/}<ENTER> //Select until the character }


    IF Surround.vim is enabled
  3. wongjiahau revised this gist Aug 12, 2017. 1 changed file with 9 additions and 1 deletion.
    10 changes: 9 additions & 1 deletion Vim mnemonics and keys
    Original file line number Diff line number Diff line change
    @@ -8,4 +8,12 @@ cw //Change small word (until any non-alphabet is reached)
    <Ctrl-a> //Add the first number in the current line by 1
    <Ctrl-x> //Xubtract the first number in the current line by 1
    180<Ctrl-a> //Add the first number in the current line by 180
    180<Ctrl-x> //Xubtract the first number in the current line by 180
    180<Ctrl-x> //Xubtract the first number in the current line by 180
    % //Go to next matching parenthesis
    `` //Snap back to where % has jumped from


    IF Surround.vim is enabled
    S" //Surround highlighted words with "
    S( //Surround highlighted words with (
    cs{[ //change surrounding brackets from { to [
  4. wongjiahau renamed this gist Aug 11, 2017. 1 changed file with 2 additions and 0 deletions.
    2 changes: 2 additions & 0 deletions Vim mnemonics → Vim mnemonics and keys
    Original file line number Diff line number Diff line change
    @@ -1,3 +1,5 @@
    W //go to next Word (separated by space)
    B //Back to previous Word (separated by space)
    dib //Delete inside bracket
    daw //Delete a word
    dtk //Delete 'till 'k'
  5. wongjiahau revised this gist Aug 11, 2017. No changes.
  6. wongjiahau revised this gist Aug 11, 2017. 1 changed file with 2 additions and 0 deletions.
    2 changes: 2 additions & 0 deletions Vim mnemonics
    Original file line number Diff line number Diff line change
    @@ -3,5 +3,7 @@ daw //Delete a word
    dtk //Delete 'till 'k'
    cW //Change big word (until a whitespace is reached)
    cw //Change small word (until any non-alphabet is reached)
    <Ctrl-a> //Add the first number in the current line by 1
    <Ctrl-x> //Xubtract the first number in the current line by 1
    180<Ctrl-a> //Add the first number in the current line by 180
    180<Ctrl-x> //Xubtract the first number in the current line by 180
  7. wongjiahau revised this gist Aug 11, 2017. 1 changed file with 5 additions and 0 deletions.
    5 changes: 5 additions & 0 deletions Vim mnemonics
    Original file line number Diff line number Diff line change
    @@ -1,2 +1,7 @@
    dib //Delete inside bracket
    daw //Delete a word
    dtk //Delete 'till 'k'
    cW //Change big word (until a whitespace is reached)
    cw //Change small word (until any non-alphabet is reached)
    180<Ctrl-a> //Add the first number in the current line by 180
    180<Ctrl-x> //Xubtract the first number in the current line by 180
  8. wongjiahau created this gist Aug 11, 2017.
    2 changes: 2 additions & 0 deletions Vim mnemonics
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,2 @@
    dib //Delete inside bracket
    daw //Delete a word