Volver al ranking

cknadler/vim-anywhere

Shell

Use Vim everywhere you've always wanted to

vimosxkeyboard-shortcutsshelltext-editor
Crecimiento de estrellas
Estrellas
3.8k
Forks
148
Crecimiento semanal
Issues
31
1k2k3k
dic 2013feb 2018may 2022jul 2026
README

vim-anywhere

CI

Sometimes, you edit text outside of Vim. These are sad times. Enter vim-anywhere!

demo

Once invoked, vim-anywhere will open a buffer. Close it and its contents are copied to your clipboard and your previous application is refocused.

Installation

Requirements

macOS:

  • MacVim (brew install --cask macvim)

Linux:

  • Gnome (or a derivative)
  • gVim

Install

curl -fsSL https://raw.github.com/cknadler/vim-anywhere/master/install | bash

Update

~/.vim-anywhere/update

Uninstall

~/.vim-anywhere/uninstall

Keybinding

macOS: ( default = ctrl+cmd+v )

You can adjust the shortcut via System Settings.

System Settings > Keyboard > Keyboard Shortcuts > Services > Vim Anywhere

Linux: ( default = ctrl+alt+v )

Gnome

$ 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'

I3WM

$ echo 'bindsym $mod+Alt+v exec ~/.vim-anywhere/bin/run' >> ~/.i3/config # remember to reload your config after

Adjust in case $mod is not set to ctrl.

History

vim-anywhere creates a temporary file in $TMPDIR/vim-anywhere (macOS) or /tmp/vim-anywhere (Linux) when invoked. These files stick around until you restart your system, giving you a temporary history.

View your history:

$ ls ${TMPDIR:-/tmp}/vim-anywhere

Reopen your most recent file:

$ vim $( ls ${TMPDIR:-/tmp}/vim-anywhere | sort -r | head -n 1 )

Why?

I use Vim for almost everything. I wish I didn't have to say almost. My usual workflow is to open Vim, write, copy the text out of my current buffer and paste it into whatever application I was just using. vim-anywhere attempts to automate this process as much as possible, reducing the friction of using Vim to do more than just edit code.

Bugs

First, make sure to read the FAQ. If you don't find the answer you're looking for there, feel free to open an issue.

Contributing

Pull requests, suggestions and issues of any kind are welcome. Make sure to check out the contribution guidelines before you submit a pull request.

License

MIT.

Repositorios relacionados
neovim/neovim

Vim-fork focused on extensibility and usability

Vim ScriptOtherneovimc
neovim.io
101.3k7k
junegunn/fzf

:cherry_blossom: A command-line fuzzy finder

GoGo ModulesMIT Licensefzfgo
junegunn.github.io/fzf/
81.9k2.8k
LeCoupa/awesome-cheatsheets

👩‍💻👨‍💻 Awesome cheatsheets for popular programming languages, frameworks and development tools. They include everything you should know in one single file.

JavaScriptnpmMIT Licensecheatsheetsjavascript
lecoupa.github.io/awesome-cheatsheets/
46.2k6.7k
helix-editor/helix

A post-modern modal text editor.

Rustcrates.ioMozilla Public License 2.0text-editorvim
helix-editor.com
45.5k3.6k
vim/vim

The official Vim repository

Vim ScriptVim Licensevimc
vim.org
40.7k6.1k
sxyazi/yazi

💥 Blazing fast terminal file manager written in Rust, based on async I/O.

Rustcrates.ioMIT Licenseasyncioconcurrency
yazi-rs.github.io
40.6k945
lapce/lapce

Lightning-fast and Powerful Code Editor written in Rust

Rustcrates.ioApache License 2.0code-editordeveloper-tools
lap.dev/lapce/
38.7k1.3k
junegunn/vim-plug

:hibiscus: Minimalist Vim Plugin Manager

Vim ScriptMIT Licensevim
junegunn.github.io/vim-plug/
35.7k1.9k
NvChad/NvChad

Blazing fast Neovim framework providing solid defaults and a beautiful UI, enhancing your neovim experience.

LuaGNU General Public License v3.0nvimneovim
nvchad.com
28.4k2.2k
ycm-core/YouCompleteMe

A code-completion engine for Vim

PythonPyPIGNU General Public License v3.0vimcode-completion
ycm-core.github.io/YouCompleteMe/
25.9k2.8k
neoclide/coc.nvim

Nodejs extension host for vim & neovim, load extensions like VSCode and host language servers.

TypeScriptnpmOtherautocompletionlanguage-client
25.2k957
syl20bnr/spacemacs

A community-driven Emacs distribution - The best editor is neither Emacs nor Vim, it's Emacs *and* Vim!

Emacs LispGNU General Public License v3.0emacsvim
spacemacs.org
24.6k4.8k