{"id":15405590,"url":"https://github.com/krisleech/turbo-vim","last_synced_at":"2025-04-14T13:32:54.776Z","repository":{"id":7996484,"uuid":"9403527","full_name":"krisleech/turbo-vim","owner":"krisleech","description":"Vim with support for Tmux, Ruby/Rails, Rspec, Git and RVM.","archived":false,"fork":false,"pushed_at":"2015-03-26T23:15:49.000Z","size":409,"stargazers_count":12,"open_issues_count":0,"forks_count":2,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-04-13T03:06:53.755Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"VimL","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/krisleech.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2013-04-12T20:53:09.000Z","updated_at":"2019-08-13T11:20:08.000Z","dependencies_parsed_at":"2022-07-17T14:30:38.821Z","dependency_job_id":null,"html_url":"https://github.com/krisleech/turbo-vim","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/krisleech%2Fturbo-vim","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/krisleech%2Fturbo-vim/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/krisleech%2Fturbo-vim/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/krisleech%2Fturbo-vim/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/krisleech","download_url":"https://codeload.github.com/krisleech/turbo-vim/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248888705,"owners_count":21178094,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-01T16:17:23.713Z","updated_at":"2025-04-14T13:32:54.729Z","avatar_url":"https://github.com/krisleech.png","language":"VimL","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Turbo VIM for Ruby/Rails\n\n```\n  _              _                   _\n | |_ _   _ _ __| |__   ___   __   _(_)_ __ ___\n | __| | | | '__| '_ \\ / _ \\  \\ \\ / / | '_ ` _ \\\n | |_| |_| | |  | |_) | (_) |  \\ V /| | | | | | |\n  \\__|\\__,_|_|  |_.__/ \\___/    \\_/ |_|_| |_| |_|\n```\n\nVim configuration with support for Ruby, Rspec, Rails, RVM and Git.\n\nThe aim is to support a terminal based workflow within a Tmux session allowing\nspecs to be run asynchronously.\n\n## Requirements\n\nVim 7.3 or better\nTmux\nTested on MacOS and Linux with Bash, Zsh and Fish shells.\n\nIntroduction to Vim: http://blog.interlinked.org/tutorials/vim_tutorial.html\n\n## Quick Install\n\nThis will install the vim configuration only:\n\n    curl https://raw.github.com/krisleech/turbo-vim/master/bootstrap.sh -o - | sh\n\nSee later for full instructions for installing Tmux and Vim, as well as manual\ninstallation of the vim configuration.\n\n## Basic Mappings\n\nThe leader is mapped to `,`\n\n### In Normal mode (`Esc` or `jj`)\n\n`,p`     - File browser (NerdTree)\n\n`,f`     - Find in Files (Ctrlp)\n\n`Space`  - Search in buffer\n\n`,a`     - Search in files\n\n`,d`     - close buffer\n\n`,D`     - close all buffers\n\n`,Space` - Remove search highlighting\n\n`//`     - Toggle comments (T-Comment)\n\n`Tab`    - Next buffer\n\n`Shift + Tab` - Previous buffer\n\n`,,`     - Toggle between last two buffers\n\n`,m`     - Jump to model\n\n`,v`     - Jump to view\n\n`,c`     - Jump to controller\n\n`,rt`    - Generate tags for project and gems\n\n### In Insert mode (`i`)\n\n`jj` - Back to normal mode\n\n`\u003ctab\u003e` - auto complete or expand snippet\n\nSee `.vimrc` for more.\n\n## Plugins\n\n### Rails\n\n*Lots* of stuff - get to know this plugin!\n\n`:A` - jump to/from test\n\n`:Rmodel` - jump to model\n\n`:Rview` - jump to view\n\n`:help rails`\n\n### vim-ruby-doc\n\nOpen documentation in a browser for the word under the cursor:\n\n`RB` for Ruby\n\n`RS` for RSpec\n\n`RR` for Rails\n\n### Turbux + Vimux (,t / ,T / ,tt)\n\n`,t` - run all tests for current buffer\n\n`,T` - run test for current line\n\n`,tt` - run all tests\n\nRuns specs in a tmux pane. Vim must be running in a tmux session for this to\nwork. If you already have the tmux window split it will send the command to run\nthe spec to that pane. Otherwise a new pane is created.\n\n### ZoomWin (,z)\n\nZoom the current window if you have multiple splits.\n\nPress `,z` again to toogle back to normal.\n\n### ruby-block\n\nProvides text-objects for Ruby blocks\n\n`var` (visual around Ruby)\n\n`vir` (visual inner Ruby)\n\n`ar` / `ir` (expand/contract selection)\n\n`cir` (change inner Ruby)\n\n`dar` (delete around Ruby)\n\nhttp://vimcasts.org/blog/2010/12/a-text-object-for-ruby-blocks/\n\n### fugitive\n\nGit integration\n\n*Lots* of stuff\n\n`,gs` and press `-` to stage file under cursor\n\n`,gc` to commit changes, you will be prompted for a message\n\nhttp://vimcasts.org/episodes/fugitive-vim---a-complement-to-command-line-git/\n\n`:help fugitive`\n\n### Ctrlp (`,f` / `,b`)\n\nFind files in your project with minimal keypresses.\n\nSearch is fuzzy so `conadus` would find `controllers/admin/users`\n\n`,f path_or_filename` (search files)\n\n`,b filename` (search buffers)\n\n`Esc` - cancel\n\n### tcomment (`//`)\n\nComment/Uncomment line\n\n### yankring\n\nShows history of yanked (copied) text\n\nAfter pasting (`p`) pressing `ctrl + p` will cycle through paste history\n\n### ag (`,a`)\n\nSearch project for text (find in files)\n\n`,a word`\n\n`,a \"some words\"`\n\nIt uses `ag` if installed, otherwise `ack`.\n\n### nerdtree (`,p`)             \n\nProject file browser\n\n`,p` opens file browser\n\n`o` / `x` open and close files/folders\n\n`m` menu to move/delete/copy files/folders\n\n`?` Help\n\nI use nerdtree for creating or moving files, but find CtrlP (`,p`) quicker for\nopening files.\n\n### surround (`ys`/`cs`/`ds`)\n\nAllows adding/removing/changing of surroundings\n\nI would highly recommend getting to know this plugin, it is very useful.\nEspecially when you grok text objects.\n\n*Characters*\n\n`ysiw)`    - surround inner word with `()`\n\n`ysiw(`    - surround inner word with `(  )`\n\nIn the above example `iw` can be replaced with any text object or motion.\n\nIf you find yourself manually adding surroundings, stop and work out the\ncorrect text object or motion.\n\n`cs\"'`     - change surrounding from `\"` to `'`\n\n`ds`       - delete surrounding\n\n*HTML tags*\n\n`yss\u003cp\u003e`  - surround line in `\u003cp\u003e` tags\n\n`cst\u003cdiv\u003e` - change surround tag to `\u003cdiv\u003e`\n\n### colorschemes\n\nLots of colourschemes, I like Solarized and desert-warm-256\n\n`:set colorscheme desert-warm-256`\n\n`:set background=dark`\n\n`:set background=light`\n\nIf you have problems with colors not displaying correctly ensure you start tmux\nin 256 colour mode: `tmux -2`.\n\n### Indent Guides (`,ig`)\n\nShow indent levels by way of vertical lines.\n\n### vundle\n\nPlugin manager and part of the reason why my vimfiles as so compact\n\n## INSTALLATION\n\nNote: If you are using RVM make sure you use system ruby before installation.\n    \n    rvm use system\n\nNote: If you already have Vim installed ensure it has support for Ruby:\n\n    vim --version | grep ruby\n\nYou should see `+ruby,` if you see `-ruby` you need to reinstall Vim with Ruby support\n\n### Install Vim and Tmux (if not already installed)\n\nAs well as installing Tmux you can grab a good tmux configration from here:\nhttps://github.com/krisleech/dotfiles/blob/master/common/tmux.conf\n\n#### MacOS\n\n    brew install vim --override-system-vim --enable-clipboard\n\nAdd `/usr/local/bin` before `/usr/bin` in your `$PATH` so you use the version of\nvim installed by Homebrew, not the one that comes with MacOS.\n\n    brew install tmux\n\n#### Debian (Ubuntu, CrunchBang)\n\n    apt-get install vim-nox\n    apt-get install tmux\n\n#### GNU/Linux from source\n\nIf you have an old GNU/Linux distro which does not have Vim 7.3 or better in its repos then install from source.\n\nThe configure options below leave out any GUI related features as I have only compiled Vim on a server.\n\nVim source is in a hg (Mercurial) repository so you need to install the hg\nclient first, e.g.  `sudo apt-get install mercurial`.\n\n    hg clone https://vim.googlecode.com/hg/ vim\n    cd vim/vim73\n    ./configure\n    ./configure --with-features=huge --enable-cscope --enable-pythoninterp --enable-rubyinterp --enable-perlinterp --enable-multibyte\n    make\n    sudo make install\n\nThis installs Vim to `/usr/local/bin,` check this is in your `$PATH` before `/usr/bin` which may contain an older system version of Vim.\n\nIf you get an error `no terminal library found` install `libncurses5-dev`.\n\n### Install these vimfiles\n\nNote: You will already have a `~/.vim` folder, either delete or move it.\n\n    mv ~/.vim ~/.vim.old\n    git clone https://github.com/krisleech/vimfiles ~/.vim\n    cd ~/.vim\n    rake install\n\nor run:\n\n    curl https://raw.github.com/krisleech/turbo-vim/master/bootstrap.sh -o - | sh\n\n#### To update to the latest vimfiles\n\n    cd ~/.vim\n    rake update\n\n#### Install Dependacies\n\n*MacOS*\n\n    brew install ack (ag is a better ack)\n    brew install ag\n    brew install ctags\n\nNote: MacOS comes with the BSD version of ctags which is not compatible.\n\n*Debian*\n\n    sudo apt-get install exuberant-ctags\n    sudo apt-get install the-silver-searcher (ag is a better ack)\n    sudo apt-get install ack-grep\n    sudo ln -s /usr/bin/ack-grep /usr/local/bin/ack\n\n## Helpful Stuff\n\n- http://github.com/krisleech/vimfiles/wiki\n- http://walking-without-crutches.heroku.com/image/images/vi-vim-cheat-sheet.png\n- http://yehudakatz.com/2010/07/29/everyone-who-tried-to-convince-me-to-use-vim-was-wrong/\n- http://stackoverflow.com/questions/1218390/what-is-your-most-productive-shortcut-with-vim/1220118#1220118\n- http://stevelosh.com/blog/2010/09/coming-home-to-vim/#important-vimrc-lines\n- `:help key-notation`\n- http://vimcasts.org/\n\n## Acknowledgments\n\n- Tim Pope (of course) http://tpo.pe/\n- https://github.com/carlhuda/janus\n- https://github.com/rson/vimfiles/blob/master/plugins.vim\n- https://github.com/codegram/vimfiles\n- https://www.destroyallsoftware.com/file-navigation-in-vim.html\n- https://github.com/alexreisner/dotfiles/blob/master/.vimrc\n- https://github.com/docwhat/homedir-vim/blob/master/vimrc/.vimrc\n- http://items.sjbach.com/319/configuring-vim-right\n- https://github.com/sickill/dotfiles/blob/master/.vimrc\n- #vim on freenode\n - woldrich\n - spiiph\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkrisleech%2Fturbo-vim","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fkrisleech%2Fturbo-vim","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkrisleech%2Fturbo-vim/lists"}