~/.vimrc#

GitHub


Configuration Details#

General Settings#

  • Syntax & Indentation:
    • syntax on: Enables syntax highlighting.
    • filetype plugin indent on: Loads filetype-specific indent files.
    • set expandtab, set shiftwidth=2, set tabstop=2: Standardizes indentation to 2 spaces.
  • UI & Feedback:
    • set number: Displays line numbers for easier navigation.
    • set showmatch: Briefly jumps to the matching bracket when one is inserted.
    • set list: Visualizes tabs and trailing spaces using listchars.
    • set scrolloff=5: Ensures context is always visible around the cursor.
  • Behavior:
    • set nohlsearch: Prevents persistent highlighting after a search.
    • set nobackup: Disables the creation of backup files.

Mappings#

  • nnoremap <C-b> <C-w>: Maps Ctrl+b to window commands (Ctrl+w). This bypasses the browser’s default behavior of closing the window when Ctrl+w is pressed in web-based IDEs like Code-server. This can be commented out if not using a web-based environment.
  • map <Space> <Plug>(easymotion-prefix): Uses the Space key as the trigger for EasyMotion.

Plugins#

Managed via vim-plug. See Plugin.