Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Vim for Visual Studio

Vim for Visual Studio

Presented at Microsoft TecHeroes, Channel 9, May 2016. See the live episode (Italian) here: https://channel9.msdn.com/Shows/TecHeroes/TecHeroes-VSVim-Editor

Nicola Iarocci

May 06, 2016
Tweet

More Decks by Nicola Iarocci

Other Decks in Programming

Transcript

  1. VSVIM FOR VISUAL STUDIO BRIEF STORY OF VIM ▸ “vi”

    dates back to 1976, for Unix systems ▸ “Vim” (Vi IMproved) debuts in 1991 ▸ Originally released on the Amiga ▸ Default on all *nix system (OSX, Linux, etc.) ▸ Available for all platforms, Windows included
  2. HERE IS WHY VIM USES HJKL AS ARROW KEYS BY

    THE WAY ADM-3A TERMINAL USED BY BILL JOY TO CODE THE ORIGINAL VI
  3. VSVIM FOR VISUAL STUDIO VSVIM ▸ A Visual Studio 2010+

    Extension ▸ Integrates familiar key binding experience of Vim directly into Visual Studio ▸ Rich set of vim features supported ▸ Created and actively maintained by Jared Parsons (MSFT) ▸ Open source, code is on GitHub ▸ Supports vim configuration files (.vimrc) ▸ ViEmu is a good alternative for previous VS versions ($)
  4. TEXT VIM VERBS ▸ d: delete ▸ c: change ▸

    y: yank (copy) ▸ v: visually select ▸ i: insert before the cursor ▸ I: insert at the beginning of line ▸ a: append after the cursor ▸ A: append at the end of line ▸ .: repeat last command ▸ … and more
  5. TEXT VIM MODIFIERS ▸ i: inside ▸ a: around ▸

    t: searches for something and stops before it (to) ▸ f: searchers for something and lands on it ▸ #: number (e.g.: 1, 2, 10) ▸ 0: begin of line ▸ ^: first word in line ▸ $: end of line ▸ … and a lot more
  6. TEXT VIM NOUNS ▸ w: word ▸ W: WORD (delimited

    by whitespace) ▸ b: beginning of word ▸ B: beginning of WORD ▸ e: end of word ▸ E: end of WORD ▸ %: matching parenthesis ▸ p or }: paragraph ▸ t: tag (HTML/XML) ▸ b: block (think code) ▸ … and more
  7. TEXT VIM “ACTIONS”: VERB+(MODIFIER)+NOUN ▸ dw: (d)elete (w)ord under cursor

    ▸ d2w: (d)elete two (w)ords ▸ cis: (c)hange (i)nside the (s)entence you are in ▸ yip: (y)ank/copy (i)nside the (p)aragraph you are in ▸ ct<: (c)hange (t)o open bracket ▸ d$: (d)elete until the end of the line ▸ … you get the idea