" Author: Marcin Szamotulski " Email: mszamot [AT] gmail [DOT] com " License: vim-license, see :help license " if !exists("g:system_expand") let g:system_expand = 1 " If 1 expand % as in the command line. endif if !exists("g:system_echocmd") let g:system_echocmd = 0 endif fun! WrapCmdLine(dispatcher) " {{{ " a:dispatcher: is crdispatcher#CRDispatcher dict let a:dispatcher.state = 1 if a:dispatcher.cmdtype !=# ':' || a:dispatcher.ctrl_f " Do not fire with return endif let cmd = a:dispatcher.cmd let cmdline = cmd.cmd " Add cmdline to the history if cmdline[0:1] == "! " let _cmd = cmdline[2:] call histadd(":", cmdline) if g:system_expand let cmd_split = split(_cmd, '\ze\\\@