jasonsturges / dotfiles

Personal dotfiles

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

dotfiles

screen-capture

Personal dotfiles of development environment

Neovim

Configuration for Neovim, Vim-based text editor.

Keybindings

Neovim key mapping, based on macOS.

Leader key: Spacebar

LazyVim and plugins

Mode Input Action
n leader l Lazy
n leader c m Mason: Language servers, linters, and formatters
n leader e Neo-tree: File system tree sidebar
n leader g g Lazygit: Terminal UI for git commands
n leader c s Aerial: Code outline
n leader s r Spectre: Search and reaplace
n leader s h Search Help
n leader s k Search Keymaps
n leader q q Quit all

Windows

Mode Input Action
n leader - Split window horizontal
n leader | Split window vertical
n leader w d Delete window: Close the current window
n leader w w Other window
n CONTROL h Go to left window
n CONTROL j Go to lower window
n CONTROL k Go to upper window
n CONTROL l Go to right window

Buffers

Mode Input Action
n SHIFT H Previous buffer (left)
n SHIFT L Next buffer (right)
n leader b d Delete buffer: Close the current buffer

Movement

Mode Input Action
nv h Move left
nv j Move down
nv k Move up
nv l Move right
nv b Previous word
nv w Next word
nv e Next end of word
nv 0 First character in line
nv ^ First non-blank character in line
nv $ End of line
nv { Previous empty line
nv } Next empty line
nv % Find next brace or bracket on the current line, and go to its match
nv g M Goto middle of line
nv g g Goto first line, beginning of document
nv G Goto last line, end of document
nv [number] g g Goto line number (also works with [number] G)
nv [number] % Goto line at number percentage (as in 25%, 50%, or 100%)
n g d Goto definition
n g D Goto declaration
n g I Goto implementation
n g y Goto type definition

Scrolling

Mode Input Action
inv SHIFT Up-Arrow Move one screenful backword (page up)
inv SHIFT Down-Arrow Move one screenful forward (page down)
nv z t Redraw current line at top of window
nv z z Redraw current line at center of window
nv z b Redraw current line at bottom of window
nv z H Scroll screen half a screen width to the right
nv z L Scroll screen half a screen width to the left

Editing

Mode Input Action
n i Insert text before the cursor
n SHIFT I Insert text before first non-blank character
n a Append text after the cursor
n SHIFT A Append text at end of line
n o New line below the current line
n SHIFT O New line above the current line
n x Delete character
n d w Delete word
n SHIFT D Delete to end of line
n d d Delete current line
n r Replace character
n R Replace mode
n u Undo
n CONTROL r Redo
inv OPTION j Move line down
inv OPTION k Move line up
nv SHIFT J Join lines (with next line, or highlighted lines)
v g c Comment (multiple lines with number g c)
v > Indent
v < Outdent
nv leader c f Format
nv leader c a Code actions
nv CONTROL n Autocompletion select from dropdown
inxs CONTROL c Exit insert mode
inxs CONTROL s Save file

Selecting

Mode Input Action
v v Enter visual mode, followed by vim movement (examples: v$, v^, or v8j)
v SHIFT V Select line
v g g V G Select all
v v i w Inner word (select word)
v v i b Inner block (select block)
v v i t Inner tag bloack
v v i " Inner quotes (select everything inside of " quotes)
v v i { Inner braces (select everything inside of {} braces)
v v i [ Inner brackets (select everything inside of [] brackets)
v v a w Outer word (select word)
v v a b Outer block (select block)
v v a t Outer tag bloack
v v a " Outer quotes (select everything including " quotes)
v v a { Outer braces (select everything including {} braces)
v v a [ Outer brackets (select everything including [] brackets)

Copying and moving text

Mode Input Action
nv y Yank into register (copy)
nv y y Yank current line into register (copy, also mapped as SHIFT Y)
nv y $ Yank from cursor to end of line register (copy)
nv y ^ Yank from cursor to first non-blank character of line (copy)
nv d Delete (cut)
nv d d Delete current line (cut)
nv p Put register after cursor (paste)
nv SHIFT P Put register before cursor (paste)
nv y i w Yank inner word (copy word)
nv d i w Delete inner word (delete word)

Searching

Mode Input Action
n * Search forward for the identifier under the cursor
n # Search backward for the identifier under the cursor
n / Search forward, repeat last search with n
n ? Search backward, repeat last search with N
n leader SPACE Find files from root directory
n leader f F Find files from current working directory
n leader / Live grep: search in all files
n s Flash: search window, use labels to jump to any location

Code Folding

Mode Input Action
n z c Close one fold under the cursor
n z C Close all folds under the cursor
n z m Fold more
n z M Close all folds
n z o Open one fold under the cursor
n z O Open all folds under the cursor
n z r Reduce folding
n z R Open all folds

File Explorer: Neo-tree

Mode Input Action
n leader e Neo-tree: Open file system tree sidebar
n RETURN Open directory or file
n a Add file
n d Delete file
n SHIFT P Preview file
n ? Help

Errors

Mode Input Action
n leader x x Document diagnostics: error list
n leader x X Workspace diagnostics: error list
n leader x q Quickfix list

TODOs

Mode Input Action
n leader x t Todos: All todos in the workspace

Git

Mode Input Action
n leader g g Git
n leader g c Git commit history

Information

Mode Input Action
n CTRL g Show current file name with path
n g a Show ascii value of character under cursor
n g 8 Show utf-8 encoding byte sequence of character under cursor
n g CONTROL G Show cursor column, line, word, and byte position

Command line

Input Action
CONTROL u Remove all characters (clear the command line)
CONTROL w Delete word in front of the cursor
CONTROL k Enter digraph

TMUX

Configuration for TMUX, terminal multiplexer.

Keybindings

TMUX key mapping, based on macOS.

Prefix: CONTROL b

Input Action
Prefix c Create window
Prefix n Next window
Prefix p Previous window
Prefix 0 Select window 0 (or enter window number)
Prefix , Rename window
Prefix w List windows
Prefix % Split window vertically
Prefix " Split window horizontally
Prefix m Toggle window maximize
Prefix z Toggle pane zoom
Prefix Arrow Cycle window focus in direction
Prefix d Detach from session
Prefix s List sessions
Prefix q Show window numbers
Prefix & Kill window
Prefix x Kill pane
Prefix COMMAND Arrow Resize pane in direction
Prefix I Install plugins

About

Personal dotfiles

License:Apache License 2.0


Languages

Language:Lua 87.0%Language:Shell 13.0%