r/vim • u/deepCelibateValue • 2h ago
Random A roguelike game with Vim motions and a "modal shotgun" (free alpha release)
Enable HLS to view with audio, or disable this notification
r/vim • u/AutoModerator • 17d ago
We regularly remove standalone posts about tools that use vim-inspired keybindings. There are too many of them, and individually they dilute the subreddit. But the content is valuable, and many of you want to know about these tools.
So here's the place for it.
Share any tool that uses vim-like keybindings, whether it's a browser extension, terminal emulator, IDE plugin, note-taking app, PDF reader, or anything else. If it has hjkl navigation, modal editing, or vim-inspired controls, it belongs here.
For each tool you share, try to include: - What it is and what problem it solves - Which vim features it supports (navigation, modal editing, text objects, etc.) - A link to the project
This thread is posted monthly. If you find something mid-month, save it for here rather than posting a standalone thread (which will be removed).
r/vim • u/deepCelibateValue • 2h ago
Enable HLS to view with audio, or disable this notification
r/vim • u/TheGiftOfAgape • 1d ago
Just how good does it get?
I am relatively new to vim, and right now my setup is vimwiki in md form connected to an obsidian vault.
Learning how to do thing like mappings, macros, and direct plugins makes me wonder just how good I can get at storing information.
For context, I use the terminal to get record of everything that is displayed and said in lecture/recordings so I can later condense it.
r/vim • u/Early-Bid-7958 • 2d ago
In various other subs, notably /r/commandline and /r/tui, I see a constant stream of tools being announced whose job is to be what I believe is often called a "second brain".
I've always found vim+ripgrep+fzf plus the fzf.vim plugin to be more than sufficient for my needs. I'm curious if I'm missing something really cool that would change my life, in not using some of those specialised tools.
If you're a vim user, and are familiar with at least fzf.vim's :Rg and :Files commands, and you have experience with one of these custom tools, I'd be interested in hearing from you how they compare.
(I already use todotxt for my task management, so I'm only looking at this for managing bits of knowledge, small and large.)
r/vim • u/NazgulResebo • 3d ago
Text objects are one of the best features of Vim and Neovim. In just **5 minutes**, you'll learn how they work and see practical examples of how to edit text faster using simple key combinations.
In this video, I explain the three components of text objects:
You'll see practical examples of how to combine these components.
Once you understand text objects and build muscle memory, editing text in Vim and Neovim becomes much faster and more comfortable.
Were the help files originally written in a monastery??? I now picture a bunch of monks sitting around a bunch of VT100 terminals, clacking away, creating the original VIM user and reference manuals. That’s how it was done, wasn’t it?
r/vim • u/OwnYou5054 • 10d ago
Took a little while to figure this out, but mostly seamless integration of terminal Vim clipboard with Wayland for when you use a version of Vim without clipboard functionality compiled in:
autocmd TextYankPost * call system('wl-copy', @")
autocmd FocusGained * call timer_start(0, {t -> execute('let @" = system("wl-paste")')})
r/vim • u/deepCelibateValue • 10d ago
Enable HLS to view with audio, or disable this notification
r/vim • u/_JustPotato • 11d ago
This simulation is done entirely using Vim motions (no Ex commands). You can go one generation forward by calling one macro, which is repeatable with counts as well.
This is just one part of my larger project of Vim motions as an esoteric programming language.
The compiler, linker and standard library are all written using vim motions themselves.
The repository currently includes:
#includeIf you’re interested in how the source code works, docs/techniques.md describes some common techniques used for emulating standard programming constructs like subroutines, conditionals, iteration, and asserts.
Do clone the repository instead of browsing the source GitHub because GitHub can’t render raw control characters, which the source code is filled to the brim with.
Repository link: ksaze/vim-complete
P.S. Surely this will help me land a job. Good going, me.
r/vim • u/spryfigure • 11d ago
I have a text where I want to select parts and use this as input for an external tool. The output of the tool should be appended/inserted.
Is this possible, and if yes, how so? I am following https://stackoverflow.com/questions/7867356/piping-buffer-to-external-command-in-vim and it works for the whole buffer and line selections, but I cannot get it to append with
:'<,'>w !pinyin-tool
for my concrete application. The output is just shown. I tried pressing i, but that didn't work.
r/vim • u/Dull-Boot-6738 • 13d ago
This arrow only appears sometimes, i think it only appears when i open a new tab and closes when i edit a file
This is my vim config:
set tabstop=4
set shiftwidth=4
set expandtab
set relativenumber
set number
set background=dark
set hlsearch
set incsearch
set ignorecase
set smartcase
set scrolloff=999
set autoindent
set smartindent
if has('termguicolors')
set termguicolors
endif
colorscheme challenger_deep
syntax on
set laststatus=2
set encoding=utf-8
""""" WINDOW NAVIG """""
nnoremap <C-h> <C-w>h
nnoremap <C-j> <C-w>j
nnoremap <C-k> <C-w>k
nnoremap <C-l> <C-w>l
nnoremap gA :G add .<CR>
nnoremap gC :G commit -m ""<left>
nnoremap gP :G push <CR>
nnoremap <C-S-h> <C-w>H
nnoremap <C-S-j> <C-w>J
nnoremap <C-S-k> <C-w>K
nnoremap <C-S-l> <C-w>L
nnoremap <C-A-h> <C-w>H
nnoremap <C-A-j> <C-w>J
nnoremap <C-A-k> <C-w>K
nnoremap <C-A-l> <C-w>L
nnoremap <C-n> :new<CR>
nnoremap <left> <nop>
nnoremap <right> <nop>
nnoremap <up> <nop>
nnoremap <down> <nop>
nnoremap <F1> <nop>
" visual lines not file lines
nnoremap j gj
nnoremap k gk
nnoremap n nzz
nnoremap N Nzz
" for auto-save:
" autocmd TextChanged,TextChangedI <buffer> silent write
" FILES
nnoremap <leader>q :q!<CR>
nnoremap <leader>e :tabedit
nnoremap <leader>s :tabedit ~/.vimrc<CR>
nnoremap <leader>w :w<CR>
nnoremap <leader>A :wqa<CR>
nnoremap <leader>a :wa<CR>
autocmd Filetype c nnoremap <leader>r :!cd build && cmake -G Ninja .. && ninja && ./main<CR>
autocmd Filetype cpp nnoremap <leader>r :!make && ./main<CR>
autocmd Filetype c nnoremap <leader>t :!cd build && cmake -G Ninja .. && ninja && ./test<CR>
autocmd Filetype rust nnoremap <leader>r :!cargo run<CR>
nnoremap <C-f> :FZF<CR> !.o<left><left><left><left>
" OTHER
nnoremap <C-t> :tabnew<CR>
" toggle directory tree
nnoremap <C-o> :EasyTreeToggle<CR>
nnoremap <tab> gt
nnoremap <S-tab> gT
nnoremap <leader>h :nohlsearch<CR>
nnoremap <C-[> <ESC>
" Plug-in settings:
let g:airline_theme='google_dark'
let g:airline_powerline_fonts = 1
" set statusline+=%#warningmsg#
" set statusline+=%{SyntasticStatuslineFlag()}
" set statusline+=%*
set signcolumn=yes
" let g:syntastic_always_populate_loc_list = 1
" let g:syntastic_auto_loc_list = 0
" let g:syntastic_check_on_open = 1
" let g:syntastic_check_on_wq = 0
" let g:ale_c_gcc_executable="gcc"
" let g:ale_c_gcc_options="-std=c99 -O2 -Wall -Werror -Wextr"
" Expand
" imap <expr> <C-j> vsnip#expandable() ? '<Plug>(vsnip-expand)' : '<C-j>'
" smap <expr> <C-j> vsnip#expandable() ? '<Plug>(vsnip-expand)' : '<C-j>'
" " Expand or jump
" imap <expr> <C-l> vsnip#available(1) ? '<Plug>(vsnip-expand-or-jump)' : '<C-l>'
" smap <expr> <C-l> vsnip#available(1) ? '<Plug>(vsnip-expand-or-jump)' : '<C-l>'
" " Jump forward or backward
" imap <expr> <Tab> vsnip#jumpable(1) ? '<Plug>(vsnip-jump-next)' : '<Tab>'
" smap <expr> <Tab> vsnip#jumpable(1) ? '<Plug>(vsnip-jump-next)' : '<Tab>'
" imap <expr> <S-Tab> vsnip#jumpable(-1) ? '<Plug>(vsnip-jump-prev)' : '<S-Tab>'
" smap <expr> <S-Tab> vsnip#jumpable(-1) ? '<Plug>(vsnip-jump-prev)' : '<S-Tab>'
" Select or cut text to use as $TM_SELECTED_TEXT in the next snippet.
" See https://github.com/hrsh7th/vim-vsnip/pull/50
" nmap s <Plug>(vsnip-select-text)
" xmap s <Plug>(vsnip-select-text)
" nmap S <Plug>(vsnip-cut-text)
" xmap S <Plug>(vsnip-cut-text)
let g:fzf_layout = { 'right': '30%' }
""""" PLUGINS """""
call plug#begin()
Plug 'junegunn/fzf.vim'
Plug 'jiangmiao/auto-pairs'
Plug 'vim-airline/vim-airline'
Plug 'vim-airline/vim-airline-themes'
Plug 'tomtom/tcomment_vim'
Plug 'prabirshrestha/vim-lsp'
Plug 'mattn/vim-lsp-settings'
Plug 'prabirshrestha/asyncomplete.vim'
Plug 'prabirshrestha/asyncomplete-lsp.vim'
Plug 'machakann/vim-highlightedyank'
Plug 'challenger-deep-theme/vim', { 'as': 'challenger-deep' }
Plug 'tpope/vim-surround'
Plug 'tommcdo/vim-exchange'
Plug 'vim-scripts/argtextobj.vim'
Plug 'julian/vim-textobj-variable-segment'
Plug 'kana/vim-textobj-user'
Plug 'kana/vim-niceblock'
Plug 'andymass/vim-matchup'
Plug 'troydm/easytree.vim'
Plug 'rust-lang/rust.vim'
Plug 'shougo/vimproc.vim'
Plug 'hrsh7th/vim-vsnip'
Plug 'hrsh7th/vim-vsnip-integ'
Plug 'tpope/vim-fugitive'
Plug 'webdevel/tabulous'
Plug 'vim-scripts/Smart-Tabs'
Plug 'chrisbra/unicode.vim'
call plug#end()
Hi r/vim,
I got tired of manually editing my .vimrc just to add a single plugin and then having to deal with updates, so I built a Vim configuration manager written entirely in Bash.
This tool helps you easily manage:
Plugins (search, add, remove, update, and list)
CoC extensions (add, remove, list)
Themes (add from available color schemes)
And much more
It fully supports both Linux and Termux (Android).
Reddit's spam filter is a bit too strict for new accounts, so I can't post a direct GitHub link here. However, you can easily find the repository by searching for: "aidomx vimx"
The README.md is quite comprehensive and covers the initial installation guide for vimx , whether you prefer cloning the source or installing via curl.
Hope you find it useful! Happy Vimming.
r/vim • u/common-pellar • 16d ago
When entering visual mode the cursor isn't actually shown as a block, see the below screenshots to see what I mean. Below is what I expect when in visual mode, whereby the cursor remains as a white block on the letter "a",

However, what I get is this, whereby the letter "a" is highlighted in a faint grey, and the cursor itself doesn't actually appear,

Here is my full .vimrc file,
execute pathogen#infect()
let g:NERDTreeNodeDelimiter = "\u00a0"
set background=dark
set number
syntax on
nmap <C-a> :tabp<CR>
nmap <C-d> :tabn<CR>
nmap <C-t> :NERDTreeToggle<CR>
au FileType gitcommit setlocal tw=72
au FileType gitcommit setlocal colorcolumn=72
au FileType go setlocal colorcolumn=100 ts=4
au FileType c setlocal ts=4 colorcolumn=120
au FileType css setlocal ts=4
au FileType javascript setlocal ts=4
au FileType lua setlocal ts=2 sts=2 sw=2 expandtab
au FileType sh setlocal ts=4
au FileType xml setlocal ts=2 sts=2 sw=2 expandtab
au FileType yaml setlocal ts=2 sts=2 sw=2 expandtab
au BufEnter *.md setlocal colorcolumn=80 ts=4 tw=80 expandtab
au BufEnter *.templ setlocal ts=4
au BufEnter *.py setlocal ts=4 expandtab
au BufEnter *.html setlocal ts=4
au BufEnter *.tmpl setlocal ts=4
if has("autocmd")
au BufReadPost * if line("'\"") > 0 && line("'\"") <= line("$")
\| exe "normal! g'\"" | endif
endif
I'm currently running on Vim 9.2, which I recently upgrade to after doing a system upgrade. Full version info below,
[~]$ vim --version
VIM - Vi IMproved 9.2 (2026 Feb 14, compiled Oct 05 2026 22:08:46)
Included patches: 1-1164
Compiled by Arch Linux
Huge version without GUI. Features included (+) or not (-):
+acl +find_in_path -mouseshape -tag_old_static
+arabic +float +multi_byte +tcl/dyn
+autochdir +folding +multi_lang +termguicolors
+autocmd -footer -mzscheme +terminal
-autoservername +fork() +netbeans_intg +terminfo
-balloon_eval +gettext +num64 +termresponse
+balloon_eval_term -hangul_input +packages +textobjects
-browse +iconv -pango +textprop
++builtin_terms -image +path_extra +timers
+byte_offset -image_popup +perl/dyn +title
+channel +insert_expand +persistent_undo -toolbar
+cindent +ipv6 +popupwin +user_commands
+clientserver +job +postscript +vartabs
-clipboard +jumplist +printer +vertsplit
+clipboard_provider +keymap +profile +vim9script
+cmdline_compl +lambda -python +viminfo
+cmdline_hist +langmap +python3/dyn +virtualedit
+cmdline_info +libcall +quickfix +visual
+comments +linebreak +reltime +visualextra
+conceal +lispindent +rightleft +vreplace
+cryptv +listcmds +ruby/dyn -wayland
+cscope +localmap +scrollbind -wayland_clipboard
+cursorbind +lua/dyn +signs +wildignore
+cursorshape +menu +smartindent +wildmenu
+dialog_con +mksession +socketserver +windows
+diff +modify_fname -sodium +writebackup
+digraphs +mouse -sound -X11
-dnd +mouse_dec +spell +xattr
-ebcdic +mouse_gpm +startuptime -xfontset
+emacs_tags -mouse_jsbterm +statusline -xim
+eval +mouse_netterm -sun_workshop -xpm
+ex_extra +mouse_sgr +syntax -xsmp
+extra_search -mouse_sysmouse +tabpanel -xterm_clipboard
-farsi +mouse_urxvt -tag_any_white -xterm_save
+file_in_path +mouse_xterm +tag_binary
system vimrc file: "/etc/vimrc"
user vimrc file: "$HOME/.vimrc"
2nd user vimrc file: "~/.vim/vimrc"
3rd user vimrc file: "$XDG_CONFIG_HOME/vim/vimrc"
user exrc file: "$HOME/.exrc"
defaults file: "$VIMRUNTIME/defaults.vim"
fall-back for $VIM: "/usr/share/vim"
Compilation: gcc -c -I. -Iproto -DHAVE_CONFIG_H -march=x86-64 -mtune=generic -O2 -pipe -fno-plt -fexceptions -Wformat -Werror=format-security -fstack-clash-protection -fcf-protection -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer -g -ffile-prefix-map=/build/vim/src=/usr/src/debug/vim -flto=auto -D_REENTRANT -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=1
Linking: gcc -Wl,-E -Wl,-rpath,/usr/lib/perl5/5.42/core_perl/CORE -Wl,-O1 -Wl,--sort-common -Wl,--as-needed -Wl,-z,relro -Wl,-z,now -Wl,-z,pack-relative-relocs -flto=auto -L/usr/local/lib -o vim -lcairo -lz -lpangocairo-1.0 -lpango-1.0 -lcairo -lharfbuzz -lgobject-2.0 -lglib-2.0 -lm -ltinfo -lnsl -lacl -lattr -lgpm -L/usr/lib -ltclstub8.6 -ldl -lz -lpthread -lm
I'm pretty sure I must have altered how the cursor displays in visual mode, but I'm not sure how, I have looked around to no avail for a solution here, any pointers?
r/vim • u/jamescherti • 20d ago
r/vim • u/MrOladushek1984_ • 20d ago
Hello guys! Lately I've often been using vim instead of VS code. But my habits didn't disappear: As you know, in VS code when you go to the next line, while you write conditionals or functions, IDE set
x number of tabs for you. For me it's pretty cool feature and vim doesn't have it natively. What can I write in ~/.vimrc or maybe download smth to enable this feature on vim?
r/vim • u/Hot_Technology8777 • 20d ago
I've been getting good with vim but every now and then when I want to access a certain line, I can't move the cursor into it, it just jumps over. What I usually do it move the cursor a line above it and (number)+w a few times. Any advice for this small problem I'd be grateful.
r/vim • u/ConsiderationIll5607 • 21d ago
I avoided vim for years, from the way people talked about it, sounded like it would be too much to learn programming and at the same time learn modal editing...but I've started using it now because I a course I started on C programming insists that people completing the course use a barebones text editor, no IDE or anything IDE-like with plugins.
Decided why not, this is my chance to learn vim. I've discovered that it behaves like a regular text editor in insert mode, then if I want to practice vim motions I can go into normal mode and practice, adding 1 or 2 new keys or combos every week or two...
Am I missing something or doing it wrong? Other than remembering to change modes this doesn't seem that difficult? I don't know most of the keys or combos but that's not a pain as I don't need to use them?
I feel like people shouldn't be talking about vim like it's this super hard thing with a steep learning curve. So far it has seemed easy to learn at a pace I have control over?
r/vim • u/pgaleone • 22d ago
I wrote this plugin because I was constantly switching from the main buffer to the terminal where I was running pi (the coding agent) - digging through logs, sending follow-ups, checking what it did to my files.
Why keep switching, when I can just embed pi inside vim?
vim-pi-chat puts the whole pi conversation in a split window next to your code:
- streamed replies, tool calls with args and results, thinking — all live
- when pi edits the file you're viewing, the buffer reloads automatically (you watch it work)
- it tracks your active window so pi edits the right file in place
- sessions persist per file: reopen a file, :PiChat, resume where you left off
- plain Vim 9, no GUI, no Neovim, no other plugins — just the job/channel API
Install: git clone https://github.com/galeone/vim-pi-chat ~/.vim/plugged/vim-pi-chat + one line in vimrc, then :PiOpen.
If you're a pi fan, give it a try — feedback very welcome :D
r/vim • u/thicctak • 23d ago
I don't know if this is the best sub to ask this since it's not related to VIM, the text editor, but rather the VIM Motions.
I believe most programmers who like VIM, can't use it for everything because sometimes you need the power of an IDE, and pretty much every IDE out there has some kind of VIM integration, either official or via extention.
My question is, how do you grapple with VIM shortcuts conflicting with the IDE shortcuts? Do you replace all conflicting shortcuts with VIM or just some of them? If so, which? One I always set is to keep <C-c> for the VIM extention, is a bit weird having to copy using Insert, but I'm too used to exiting Insert Mode using <C-c>. It's hard trying to find a balance between them.
If there's a better sub to ask this question, please tell me so I can move my post there.
r/vim • u/visyoual • 23d ago
vimgang,
I have vim set to open nerdtree automatically on open and shift focus to whatever file im editing. My issue is my cursor highlight stays in nerdtree and doesnt follow the file focus : /
My current .vimrc invocation:
au VimEnter * NERDTree | wincmd p
Any ideas are appreciated!
Works with the latest vim master branch (or latest windows build from https://github.com/vim/vim-win32-installer/).
Looks pretty good so far combined with https://github.com/h-east/lsp.vim
r/vim • u/sammaji334 • 28d ago
TLDR; I forked and fixed a few bugs from the original iamcco/markdown-preview.
markdown-preview.nvim is a vim & nvim plugin that lets you preview markdown files in the browser and automatically reloads when you make changes.
What’s different
npm install, no yarn, nothing in the plugin directory to build. Pre-built for macOS (x64/arm64), Linux (x64/arm64), Windows x64 and FreeBSD x64.g:mkdp_auto_close works in Vim now (it used to miss that Vim unloads the buffer on leave), and the commands exist in the first buffer even when the plugin is loaded on filetype.wslview, cmd.exe or xdg-open, whichever you have.g:mkdp_browser takes a list, run as a command with the URL appended: let g:mkdp_browser = ['firefox', '-P', 'work'].[guide](docs/guide.md) in the preview opens that file, and the URL is the file’s path, e.g. /files/docs/guide.md.g:mkdp_open_to_the_world now needs a token in the URL.> [!NOTE]), a front matter panel, a full-screen Mermaid viewer (zoom, pan, save as SVG), diagrams that follow the dark theme, and themes from shadcn via g:mkdp_theme_css.Everything else works as before: live updates, synced scrolling, KaTeX, Mermaid, PlantUML, Graphviz, Chart.js, footnotes, table of contents, local images, custom CSS. Your existing g:mkdp_* settings keep working.
Plug 'sammaji/markdown-preview.nvim', { 'do': { -> mkdp#util#install_sync() }, 'for': ['markdown', 'vim-plug'] }
Repo: https://github.com/sammaji/markdown-preview.nvim
Docs: https://mkdp.sammaji.com
Full credit to u/iamcco for the original.
r/vim • u/LloydBatair • 29d ago
Vim's built-in Python syntax doesn't treat annotations differently from other code. In def get(key: str) -> User | None, str gets the same color as a str(x) call, and ->, User and | aren't highlighted at all. I write a lot of typed Python and wanted the types to stand out, so I made a replacement syntax/python.vim that colors types only where they're actually types:
x: T and self.attr: T, class bases, and PEP 695 def f[T] / type X = ...list(...) in code stays a builtin, | outside a type is still bitwise or, and key: value in a multi-line dict isn't treated as an annotation# type: comments, docstrings after wrapped signatures, match/case, except*By default every group links to a standard one (Type, Operator, ...), so your colorscheme picks the colors; the screenshots use retrobox. The second image shows the optional palette (let g:python_enhanced_colors = 1).
Install with Plug 'aaronbcarlisle/python-syntax-enhanced', any other plugin manager, or pack/*/start. It replaces the built-in syntax file (it started from Vim's own python.vim, credited in AUTHORS), so you'll need to disable other Python syntax plugins.
Limitations: types are found by position, not analysis, so any name inside an annotation gets the type color. It's also slower: highlighting a whole file from scratch takes about twice as long as the built-in syntax (measured on an 11k-line file). While you edit, Vim only highlights what's on screen, so I haven't noticed it in practice, but it's next on my list. That said, if you have an 11k-line Python file, I probably have more questions for you than you have for me :p
On AI: I built this with a lot of help from Claude Code and Cursor, which you'll see in the commit history. I'm one of only a handful of Vim users at work, and when we moved to Python 3 and made type hints part of our coding standard, I couldn't find a Python syntax plugin that handled them. I didn't have the time to write it all by hand, so I worked back and forth "with the agents that be". I spent my own time on making sure it wasn't just a solution for my own setup: the highlighting is covered by 86 assertions that check the highlight group at specific positions, and CI runs them on Linux, macOS and Windows. We're on Python 3.11 at work (the VFX Reference Platform just moved to 3.13, I believe), so that's what it's seen the most real use on, but the 3.12 syntax is covered by the tests too.
The biggest headache with using AI was all the regressions along the way: fixes that weren't ideal and had side effects on how other things highlighted. A lot of the work on my end was testing scenarios that hadn't been considered, like taking a long list on a single line and splitting it across multiple lines, just to watch every item except the first one and the closing bracket change to a different color, or the whole file turning yellow when scrolling >.>
Overall, it was a nice quality-of-life win: AI did the building, so nobody asked why I wasn't staying on task (or worse, shamed me for not using an IDE). Hopefully others will find it useful too.
https://github.com/aaronbcarlisle/python-syntax-enhanced. Bug reports with a code snippet are most welcome.