Falldio / nvim

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

My NeoVim

Yet another NeoVim configuration~

Basic Vim guidance should be found here!

__   __    _       _  __     _
\ \ / /__ | | ___ | |/ /___ | | ___   _ _ __ __ _
 \ V / _ \| |/ _ \| ' // _ \| |/ / | | | '__/ _` |
  | | (_) | | (_) | . \ (_) |   <| |_| | | | (_| |
  |_|\___/|_|\___/|_|\_\___/|_|\_\\__,_|_|  \__,_|

[TOC]

Key bindings

This chapter gives a summary of custom key bindings, click here for more detailed information.

Cursor Control (Normal & Visual)

Key Control
Space + s quick select text objects

General Commands

Key Control
T open tagbar to view code structure
: + e + filepath open file
g + f open file at the path where cursor is pointing at
z + z set the current line to the center of the screen
: + % + Tohtml export current file as a html file (so you can save it PDF, etc)
m + p/ markown preview
F1 toggle undotree

Code Reformat

Key Control
Space + s + c toggle spell check
z + = open spell correct suggestion
Ctrl + x open complete suggestion
: + Tabularize align text
Ctrl + q reformat code of the whole file

File Open Shortcuts

Key Control
Space + z + r + c open init.vim in NeoVim
Space + r + c open init.vim in NeoVim
Space + f open Fuzzy File Finder to open a file in a new tab
t + t open NerdTree to open a file in a new tab
Space + RM open README.md

Screen Split & Tabs & Buffers

Key Control
Ctrl + w + h / v split windows horizontaly or verticaly
Space + Direction Key switch window
Up / Down / Left / Right adjust window size

Search

Key Control
/ + query + Enter search something
Space + Enter clear search results
n find next result
N find previous result

Placeholder

Key Control
Space + Space find the next placeholder, clear it and switch into insert mode
Space + p + h insert a placeholder at current position

Comment

Key Control
Space + c + c comment
Space + c + u uncomment
Ctrl + c comment toggle

Numbers

Key Control
Ctrl + a add number by 1

For fun!

Key Control
Space + logo convert the input string into a nice digital artwork!
Space + g + y Zen mode!

Plugins

This chapter includes all plugins used in this NeoVim config.

UI-relevant

Function Enhancement

Just for fun~

  • vim-FIGlet: enables figlet input in Vim!
  • vim-startify: display a cute start screen when launching nvim/vim without a specific file path.
  • goyo.vim: Zen mode~

Navigation

  • nerdtree: a file system explorer for Vim.
  • tagbar: get an overview of the current code structure.

Enhancement for specific languages

Git

  • conflict-marker.vim: visualize git conflicts and jump between them.
  • vim-fugitive: a Git wrapper for vim/nvim. Call :Git or :G to execute git commands.
  • vim-signify: use the left gutter to indicate code status managed by a version control system (VCS).
  • vim-gitignore: provide highlighting and code snippets for .gitignore file.

Dependencies

About


Languages

Language:Vim Script 100.0%