Showing posts with label vim. Show all posts
Showing posts with label vim. Show all posts

Monday, September 1, 2014

Kamailio.cfg – auto-complete plugin for vim


Kamailio VIM plugin

I have  published a vim plugin offering basic autocomplete for Kamailio configuration file. It  is now available now via github at:
More details about the plugin (including how to install and use) can be read at:
While developed more as a proof of concept so far, it is functional and can help writing easier Kamailio configuration files. Hopefully interested people will join development to bring it to a ‘smarter auto-complete’ plugin.
Right now it relies on custom autocomplete feature from vim — once activated, as you type a word, by pressing CTRL+x CTRL+u a pop up box presents possible completion by matching the typed part of the word.
The dictionaries include module functions and parameters, script variables, core functions and parameters (they were generated with some scripts grepping various files, thus they might not be complete).
It is not (yet) aware of context, so it displays all matches (e.g., even when in a route block, it displays core parameters), so again, everyone is welcome to contribute/fork/pull requests to develop the plugin further. The readme lists some other goals as well.
Hopefully it is going to be useful at least for some people in the community!

Thursday, July 30, 2009

MacBookPro - low budget keyboard - vim and mc

I realized that the very hyper glamorized MacBookPro (and probably the other variants) was designed against portability, developers and system administrators.

While every application (ahh, before getting in to this apple stuff) built its navigation system having in mind few "standard" keys, most of them are missing on MacBookPro keyboard: Page Up, Page Down, Home, End (Insert, Delete, ...). There is no indication on the keyboard what combination of keys to press to get them.



Of course, because it is not something standard, you have to remember for each application the combination or try blindly CMD, SHIFT, CTRL, ALT plus UP, DOWN, LEFT or RIGHT (BACKSPACE). If you are lucky you may get it. If you are "very lucky" you may screw up what you do because the combination you just tried does something else.

Considering opening an account to make donations for future versions to overcome this...

Google did its job this time as well. Here are some hints for guys doing remote administration via terminal.

Midnight Commander - nightmare commander without INSERT key - you are saved by CTRL+t.

I nice guide to start with Midnight Commander can be found here. Default hotkeys bindings can be found on project's web site.

Vim is classic and designed to be terminal independent, therefore has lot of direct keyboard shortcuts
  • type 'i' to get in insert mode
  • '$' and '^' to jump to start of line end of line in command mode
See here a comprehensive list of vim tips.

Also take in consideration a 5 bucks usb keyboard - can save you some nerves (and the macbook) during migration time.

Monday, May 19, 2008

openser.vim

I just found VIM OPENSER syntax specs for configuration file, courtesy of Stanislaw Pitucha. As a heavy VIM user, I am glad to have it available. You can download it from the VIM site.

http://www.vim.org/scripts/script.php?script_id=2242