Git Product home page Git Product logo

vim-anywhere's Introduction

vim-anywhere

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 it's contents are copied to your clipboard and your previous application is refocused.

Installation

Requirements

OSX:

  • MacVim (brew install macvim)

Linux:

  • Gnome (or a derivative)
  • gVim

Install

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

OSX caveat: key binding is unbound by default. See keybinding for details.

Update

~/.vim-anywhere/update

Uninstall

~/.vim-anywhere/uninstall

Keybinding

OSX: ( default = unbound, suggested = ctrl+cmd+v )

The keyboard shortcut for invoking vim-anywhere is unbound by default on OSX. The installation script will automatically open System Preferences > Keyboard > Shortcuts. Fill in the following:

keyboard shortcut

Linux: ( default = ctrl+alt+v )

$ gconftool -t str --set /desktop/gnome/keybindings/vim-anywhere/binding <custom binding>

History

vim-anywhere creates a temporary file in /tmp/vim-anywhere when invoked. These files stick around until you restart your system, giving you a temporary history.

View your history:

$ ls /tmp/vim-anywhere

Reopen your most recent file:

$ vim $( ls /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 applicaiton 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.

Roadmap

  • ☐ Find a way to automate setting vim-anywhere's keyboard shortcut (OSX)
  • ☒ Gnome support
  • ☐ KDE support

Contributing

Love vim-anywhere? Hate it? Want to change it completely? Email me or open and issue and lets talk. Pull requests, suggestions and issues of any kind are welcome with open arms.

License

MIT.

vim-anywhere's People

Contributors

jtheoof avatar exhuma avatar lavignes avatar mlr avatar soli avatar

Watchers

James Cloos avatar Jonathan Harris avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.