NeoVIM

Environment

To run NeoVIM with a specific config located in ~/.config/<dir>, you can pass it to the environment variable:

$ NVIM_APPNAME=<dir> nvim

Shortcuts

  • space: Leader key
  • jk / kj : Exit mode

Par défaut

  • Ctrl + direction : Change windows
  • Shift + direction : Change dimensions
  • TAB : Change buffer
  • Shift + TAB : Change buffer from back
  • leader + bd : Delete buffer
  • leader + ss : Stop research
  • Ctrl + a : Decrement a number
  • Ctrl + x : Increment a number
  • Ctrl + o : Go to the previous point before jump
  • Ctrl + i : Go to the next point before jump
  • Ctrl + e : Scroll up
  • Ctrl + y : Scroll down
  • Macros:
    • q<name><macro>q => record
    • <nombre>@<name> => call

Vim-surrounding

  • cs<symbole><new symbole> => Change surrounding
  • ds<symbole> => Delete surrounding
  • ys => you surround
    • ysiw<symbole> => Surround word
    • yss<symbole> => Surround line
  • VISUAL:
    • S<symbole> => Surround selection

Nerdcommenter

  • leader + cc : Comment
  • leader + ci : Inverse comment / uncomment

Telescope

  • leader + ff : Walk through git files
  • leader + fg : Walk through code
  • leader + b : Walk through buffers

Completion

TODO

LSP

  • leader + ld => Go to definitions
  • leader + lr => Rename
  • leader + lf => Format
  • leader + lt => Go to type definition
  • leader + lx => Go to the reference
  • leader + la => Change workspace
  • leader + lc => Completion
  • leader + lh => Object informations
  • leader + ls => Document symbols
  • leader + lm => Display menu

Mardown

  • leader + wp => Show markdown
  • Format paragraphs:
    • v (and selection) + gw: unify size for line (old version)
    • v (and selection) + gq: unify size for line (old version of Neovim)

Resources