Skip to content

abeldekat/nvim_pde

Repository files navigation

Neovim pde

My personal development environment for Neovim

Older versions

Note

Tag with_submodules references the version containing git submodules, lazy.nvim and mini.deps

Tag with_lazynvim references the version containing lazy.nvim and mini.deps

Structure

Install

Requirements: Neovim latest version or nightly.

Always review the code before trying a configuration.

Clone the repository:

git clone https://github.com/abeldekat/nvim_pde ~/.config/ak

Open Neovim with this config, installing the plugins:

NVIM_APPNAME=ak nvim

Remove the config:

rm -rf ~/.local/share/ak ~/.local/state/ak ~/.cache/ak
rm -rf ~/.config/ak

Note: For peek.nvim, deno needs to be installed.

Workflow

I touch type using the right hand in combination with the forefinger of the left hand

  • Leader: space
  • Main plugins: mini.visits, oil, mini.pickand mini.jump2d
  • I configured mini.visits to operate in almost the same way as grapple.nvim
  • Menu: mini.clue

Visits

  • Info in statusline: custom statusline component visitsline
  • Toggle current label on file: <leader>a
  • The shortcuts normally used for window navigation correspond to file 1-4: c-j, <c-k>,<c-l>,<c-h>
  • Pick files having current label: <leader>j ("strongest finger")
  • Pick all labeled files: <leader>,
  • Switch context(label): <leader>oj
  • Maintain label: <leader>om
  • Remove label from files: <leader>or

Window navigation

  • <c-w>hjkl (stock Neovim)
  • mw(next window)
  • me(last accessed window)

Oil

  • mk("rolling fingers"), opening oil
  • h up one level
  • l down one level, open file

Tmux

  • tmux-sessionizer inspired by @ThePrimeagen
  • workspaces at the top of the screen, using tmuxp
  • leader: ctrl space
  • navigation:
    • tmux-sessionizer: leader h
    • previous session: leader j
    • previous window: leader l
    • existing sessions: leader k
    • switch pane: leader o

UI

  • mini.statusline, no colors, except on:
    • mode change
    • diagnostics
    • current buffer has current label (mini.visits)
    • macro recording
  • many color-schemes

Change color-schemes:

  • on each startup, see scripts, vim_menu_owns
  • mini.pick, leader f o c, loads all colors, does not show builtin color-schemes
  • change the palette of the current color-scheme using leader h

Script vim_menu_owns writes to lua.ak.colors. Ignoring changes to that file:

git update-index --assume-unchanged lua/ak/colors.lua

Key conflicts

Replace replace with substitute mnemonic:

In my config, the suggested key gr("go replace") in mini.operators is already used for the lsp("go references").

I prefer "two character hotkeys" as I use some lsp keys quite often(gd, gr).

Solution: Change operator gr into gs, mnemonic for "go substitute".

Consequences:

Mini

Many of the excellent modules included in mini.nvim are used in this config:

ai, align, animate, base16, clue, cursorword, deps, diff, git, hipatterns, hue, icons, indentscope, jump2d, move, notify, operators, pairs, pick, splitjoin, starter, statusline, surround, visits

Relevant discussions:

Environment

tmux alacritty zsh scripts awesome arch linux

Acknowledgements

This repo uses code and ideas from the following repositories: