1 USING: editors io.standard-paths kernel make math.parser
2 namespaces sequences strings ;
11 editor-class [ vim ] initialize
15 HOOK: find-vim-path editor-class ( -- path )
17 HOOK: vim-ui? editor-class ( -- ? )
21 M: vim-base vim-ui? f ;
23 M: vim-base find-vim-path "vim" ?find-in-path ;
25 : actual-vim-path ( -- path )
26 \ vim-path get [ find-vim-path ] unless* ;
28 M: vim-base editor-command
30 actual-vim-path dup string? [ , ] [ % ] if
31 vim-ui? [ "-g" , ] when
32 vim-tabs? get [ "--remote-tab-silent" , ] when
33 number>string "+" prepend ,
37 M: vim-base editor-detached? f ;