Integrake : Abuse Rake to do project chores around Vim
| script karma
Downloaded by 2240
Comments, bugs, improvements
script versions (upload new version)
|GitHub repository: https://github.com/idanarye/vim-integrake
Build systems were originally created to script the build process, but they can do much more - they are actually a great way to organize and run all the project-specific, development-related scripts. You can keep all the scripts for running the project, running unit-tests, cleaning, deploying etc. as different tasks(or targets) in a single build file, and easily run specific tasks from the command-line.
Integrake takes this one step farther - it uses Vim's ruby interface and the Rake API to load Rakefiles and run Rake tasks inside the Vim environment. Integrake tasks, are written in Ruby - which means power, elegance and access to any gem you want - and executed in the environment of the current Vim instance - which means you can interact with the buffers, change settings, modify global Vim variables and execute the commands of your Vim plugins.
Integrake also assists in creation and editing those Integrake tasks, and allows you to easily copy project-type-general Integrake file that you made in advance.
For example - you might always want a :run task that runs your project with specific input(that you often change) and see if it behaves like you want.
If the project is a command line application - you will simply want execute it in a shell. Nothing fancy here.
If it's a web service, you want to send an HTTP request to it and display the result. Since Integrake is written with Ruby, you can use Ruby's default HTTP library - install an alternative, easier-to-use library using RubyGems - to easily send that request.
Some languages and frameworks are painful to run from the command line, but have a Vim plugin that helps running their projects. Since Integrake runs in the environment of the current Vim instance, you can use those plugins from inside the :run task.
Since you always use the same task name - :run - you can have a global key mapping that runs your project in the appropriate way, no matter which type of project it is. And since the task is defined in a file in the project's directory, you can easily change the run arguments to test different things in your project, without having to remap the key.
* Ruby installed on your computer(Tested with Ruby 1.9 and 2.0)
* Vim compiled with ruby support(check with ":echo has('ruby')" from Vim)
* Rake gem installed(install with "gem install rake" from the command line)
See ":help integrake-configuration" for configuration details.
Click on the package to download.
ip used for rating: 126.96.36.199
||- Automatically add a task for querying the chosen option of Integrake.option
- Allow passing the option to Integrake.option as an argument
- Add a new prepared autocompletion - :list
- Add input_list - an improved version of Vim's inputlist()
- Fix a bug that prevented invoking IR from regular & block visual mode
|| - Add a mechanism for passing data from prerequisites to caller tasks.
- Add option-choosing tasks.
- Add window preparation tasks.
- Add autocompletion with the complete method for `Rake::Task`.
- Isolate the integrake file from the rest of the Vim ruby environment.
- Add `to_vim` for Hash.
||Fix a bug where do_in_window crash when there are no results
||Add functions for operating in Vim windows:
- `find_window_numbers` and `find_window_number` for finding window
- `do_in_windows` and `do_in_windows` for running code in certain
Also fix a bug where you can't run commands with `!`
|| Removed a duplicate `IR` tag from the doc. Just because it causes an error on pathogen's `:Helptags`...