vim-anywhere: Open Vim for Text Editing in Any macOS or Linux App
Use Vim everywhere you've always wanted to
At a glance
- What is it?
- vim-anywhere is a Shell utility that opens a Vim buffer from a global keyboard shortcut, then copies the buffer contents to the clipboard and returns focus to the original application when the buffer is closed. It automates the workflow of writing in Vim and pasting the result into another program.
- Who is it for?
- vim-anywhere suits Vim users on macOS or Linux who regularly write text in applications that do not support Vim bindings, such as web forms, email clients, or chat interfaces, and want to reduce the friction of switching contexts. It does not work on Windows and requires a Gnome or Gnome-derivative desktop on Linux.
- Can I use it commercially?
- Yes. MIT is a permissive licence: you can use, modify and sell software built on it, as long as you keep its copyright and licence notices.
- Is it still maintained?
- Yes. The repository last received commits 151 days ago.
- What is it written in?
- Mainly Shell, according to GitHub's language statistics.
Answers come from the project's GitHub data, last synced on September 30, 2026, and from our analysis. They are not legal advice.
Editorial analysis
The Problem vim-anywhere Solves
Vim users who spend most of their time in the editor tend to find text entry in other applications slow and uncomfortable. The usual workaround is to open Vim, write the text, copy it, and paste it into the target application. vim-anywhere automates that sequence: a global keyboard shortcut opens a Vim buffer from wherever you are, and closing the buffer copies its contents to the clipboard and returns focus to the previous application.
The README describes the project's purpose directly: it is for Vim users who use Vim for almost everything and want to reduce the cases where they cannot. The last push was on 2026-05-02, and the project is licensed under MIT.
Installation Requirements and the Install Script
On macOS, vim-anywhere requires MacVim, which can be installed via Homebrew:
brew install --cask macvimOn Linux, it requires gVim and a Gnome desktop environment or a derivative. Once the prerequisite is met, the installer runs from a single curl command:
curl -fsSL https://raw.github.com/cknadler/vim-anywhere/master/install | bashThe installer places files in `~/.vim-anywhere`. Two management scripts are also included. To update vim-anywhere:
~/.vim-anywhere/updateTo remove it entirely:
~/.vim-anywhere/uninstallAll three scripts live in the repository root and in the installed location. The project has no published GitHub releases; updates are pulled directly from the master branch.
Keybinding Configuration on macOS, Gnome, and i3wm
The default keyboard shortcut on macOS is `ctrl+cmd+v`. It can be changed through System Settings:
System Settings > Keyboard > Keyboard Shortcuts > Services > Vim AnywhereOn Linux with Gnome, the default is `ctrl+alt+v`. The keybinding is set through `gsettings`:
gsettings set org.gnome.settings-daemon.plugins.media-keys.custom-keybinding:/org/gnome/settings-daemon/plugins/media-keys/custom-keybindings/vim-anywhere/ binding '<Primary><Alt>v'For i3wm, the shortcut is added to the i3 config file:
echo 'bindsym $mod+Alt+v exec ~/.vim-anywhere/bin/run' >> ~/.i3/configThe README notes to adjust the command if `$mod` is not set to `ctrl` in your i3 configuration, and to reload the i3 config after making changes. The `bin/run` script is the entry point that vim-anywhere uses to open the Vim buffer and wait for it to close.
The Temporary File History
Each time vim-anywhere is invoked, it creates a temporary file. On macOS, these files go into `$TMPDIR/vim-anywhere`. On Linux, they go into `/tmp/vim-anywhere`. The files persist until the system is restarted, giving access to recent editing sessions.
To view all files from previous vim-anywhere invocations:
ls ${TMPDIR:-/tmp}/vim-anywhereTo reopen the most recent file in Vim:
vim $( ls ${TMPDIR:-/tmp}/vim-anywhere | sort -r | head -n 1 )This is a practical feature for recovering text from a session that was accidentally closed before pasting, or for reviewing what was written earlier in a work session. The files are plain text and persist as long as the system has not been restarted.
Where vim-anywhere Falls Short
The most significant limitation is platform coverage. vim-anywhere supports macOS and Linux only. The README makes no mention of Windows support, and there is no included workflow or script for Windows. Engineers on Windows who want Vim bindings everywhere need a different tool.
On Linux, the supported desktop environment is Gnome or a derivative. The README also provides i3wm configuration, but the tooling assumes a graphical display environment; it does not work in headless or terminal-only setups.
The macOS requirement for MacVim, a GUI application, means that the neovim or terminal Vim distributions common among developers do not work out of the box. The project is built around opening a graphical Vim window, which is the mechanism for capturing when the buffer is closed.
Once the buffer is closed, the entire contents are copied to the clipboard as a single paste operation. There is no incremental sync or live sharing of changes between the Vim buffer and the target application. If you need to interleave Vim editing with the target application, you have to close and reopen the buffer for each editing session.
Compared to Browser-Level Vim Extensions
vim-anywhere operates at the operating system level: it intercepts a global keyboard shortcut and works across any graphical application, including web browsers, native apps, and email clients. This is its main practical advantage over browser extensions that only add Vim keybindings inside the browser.
Browser extensions such as Vimium or Surfingkeys add Vim-style navigation and sometimes text editing within browser input fields. They do not open a full Vim editor; they provide keybinding emulation within the browser's text fields. For users who primarily write in browser-based applications, a browser extension covers the common case with less setup.
vim-anywhere is useful when the text entry is outside the browser: native application text fields, desktop email clients, or any application where browser extensions cannot reach. It is also useful when the task requires Vim's full editing capabilities, such as macros, registers, or specific motions, rather than basic insert-mode keybindings.
Editorial conclusion
vim-anywhere suits Vim users on macOS or Linux who regularly write text in applications that do not support Vim bindings, such as web forms, email clients, or chat interfaces, and want to reduce the friction of switching contexts. It does not work on Windows and requires a Gnome or Gnome-derivative desktop on Linux. Before installing, confirm that MacVim is available on macOS or that gVim and a supported desktop environment are present on Linux.
Frequently asked questions
Does vim-anywhere work on Windows?
The README lists macOS and Linux as supported platforms only. There is no Windows support mentioned in the repository.
Can I use Neovim instead of Vim with vim-anywhere on macOS?
The macOS requirement listed in the README is MacVim, the graphical Vim application available via brew install --cask macvim. The README does not document Neovim as a supported alternative.
How do I recover text from a previous vim-anywhere session?
vim-anywhere saves each session as a temporary file in $TMPDIR/vim-anywhere on macOS or /tmp/vim-anywhere on Linux. Run ls ${TMPDIR:-/tmp}/vim-anywhere to list them, or use vim $( ls ${TMPDIR:-/tmp}/vim-anywhere | sort -r | head -n 1 ) to reopen the most recent file.
Official sources
Add this badge to your README
If you maintain this project, the badge below links readers to this analysis and shows its maintenance status from the daily GitHub snapshot. Paste the markdown into your README; add ?metric=license or ?metric=stars to the image URL for a different field.
[](https://hysenlabs.com/projects/cknadler-vim-anywhere)