UsingVim: Difference between revisions
(Imported from Redmine) |
|||
Line 19: | Line 19: | ||
<pre>src = gr.vector_so</pre> | <pre>src = gr.vector_so</pre> | ||
then hit Ctrl-Space and it will autocomplete that for you, give a function definition while you're typing etc. | then hit Ctrl-Space and it will autocomplete that for you, give a function definition while you're typing etc. | ||
* [https://github.com/scrooloose/syntastic Syntastic] - Static syntax checker | * [https://github.com/scrooloose/syntastic Syntastic] - Static syntax checker | ||
* [https://github.com/tpope/vim-fugitive Fugitive] - Git integration | * [https://github.com/tpope/vim-fugitive Fugitive] - Git integration |
Revision as of 12:14, 20 March 2017
Using VIM for GNU Radio development
The VIM text editor is a popular choice among coders. If you're using VIM, this page might have some advice on how to optimize your workflow.
This is no introduction to Vim!
The grproject plugin
Available from github .
This plugin is a small extension that gives Vim some idea about the code structure. Say you're editing a GNU Radio block and call :make -- in most cases nothing will happen, because you have to be in the build-directory of your module. grproject.vim tweaks paths around such that in most cases, the right thing happens. Using this plugin will allow to :cn, gf, :make and other things and Vim will more often than not actually find the relevant files.
Other useful 3rd-party plugins
Of course, there are hundreds of nice and useful Vim plugins. Here are a few which help specifically when writing C++ and Python code:
- Pathogen - If you're not using this already, you should. It organizes plugins.
- Jedi-vim - This plugin provides smart autocompletion for Python scripts. E.g., you can type
src = gr.vector_so
then hit Ctrl-Space and it will autocomplete that for you, give a function definition while you're typing etc.