vifm / vifm.vim

Vim plugin that allows use of vifm as a file picker
335 stars 19 forks source link

Got non-zero code from vifm: 1 #14

Closed rockandska closed 6 years ago

rockandska commented 6 years ago

Hi,

I've tried to install the plugin on vim but hit the error bellow when i use ":EditVifm" :

Got non-zero code from vifm: 1 

I tried with a fresh install to be sure but it failed too. (running under xfce4-terminal 0.6.3)

$ echo $TERM
xterm-256color

$ lsb_release -d
Description:    Ubuntu 16.04.3 LTS

$ sudo apt-get install vifm

$ vim --version
VIM - Vi IMproved 7.4 (2013 Aug 10, compiled Nov 24 2016 16:44:48)
Included patches: 1-1689
Extra patches: 8.0.0056
Modified by pkg-vim-maintainers@lists.alioth.debian.org
Compiled by pkg-vim-maintainers@lists.alioth.debian.org
Huge version without GUI.  Features included (+) or not (-):
+acl             +farsi           +mouse_netterm   +tag_binary
+arabic          +file_in_path    +mouse_sgr       +tag_old_static
+autocmd         +find_in_path    -mouse_sysmouse  -tag_any_white
-balloon_eval    +float           +mouse_urxvt     -tcl
-browse          +folding         +mouse_xterm     +terminfo
++builtin_terms  -footer          +multi_byte      +termresponse
+byte_offset     +fork()          +multi_lang      +textobjects
+channel         +gettext         -mzscheme        +timers
+cindent         -hangul_input    +netbeans_intg   +title
-clientserver    +iconv           +packages        -toolbar
-clipboard       +insert_expand   +path_extra      +user_commands
+cmdline_compl   +job             -perl            +vertsplit
+cmdline_hist    +jumplist        +persistent_undo +virtualedit
+cmdline_info    +keymap          +postscript      +visual
+comments        +langmap         +printer         +visualextra
+conceal         +libcall         +profile         +viminfo
+cryptv          +linebreak       -python          +vreplace
+cscope          +lispindent      +python3         +wildignore
+cursorbind      +listcmds        +quickfix        +wildmenu
+cursorshape     +localmap        +reltime         +windows
+dialog_con      -lua             +rightleft       +writebackup
+diff            +menu            -ruby            -X11
+digraphs        +mksession       +scrollbind      -xfontset
-dnd             +modify_fname    +signs           -xim
-ebcdic          +mouse           +smartindent     -xsmp
+emacs_tags      -mouseshape      +startuptime     -xterm_clipboard
+eval            +mouse_dec       +statusline      -xterm_save
+ex_extra        +mouse_gpm       -sun_workshop    -xpm
+extra_search    -mouse_jsbterm   +syntax          
   system vimrc file: "$VIM/vimrc"
     user vimrc file: "$HOME/.vimrc"
 2nd user vimrc file: "~/.vim/vimrc"
      user exrc file: "$HOME/.exrc"
  fall-back for $VIM: "/usr/share/vim"
Compilation: gcc -c -I. -Iproto -DHAVE_CONFIG_H   -Wdate-time  -g -O2 -fPIE -fstack-protector-strong -Wformat -Werror=format-security -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=1      
Linking: gcc   -Wl,-Bsymbolic-functions -fPIE -pie -Wl,-z,relro -Wl,-z,now -Wl,--as-needed -o vim        -lm -ltinfo -lnsl  -lselinux  -lacl -lattr -lgpm -ldl     -L/usr/lib/python3.5/config-3.5m-x86_64-linux-gnu -lpython3.5m -lpthread -ldl -lutil -lm      

$ vifm --version
Version: 0.7.8
Git commit hash: 
Compiled at: Feb  7 2016 13:44:37

Support of extended keys is on
Parsing of .desktop files is enabled
Without GTK+ library
With magic library
With X11 library
Without dynamic loading of X11 library
With file program
With -n option for cp and mv
Without remote command execution

$ cat .vimrc
" Vim-Plug start
call plug#begin()

" File/Buffer manager
Plug 'vifm/vifm.vim'

" Initialize plugin system
call plug#end()

$ tree .vim 
.vim
├── autoload
│   └── plug.vim
└── plugged
    └── vifm.vim
        ├── autoload
        │   └── vifm
        │       ├── edit.vim
        │       └── globals.vim
        ├── doc
        │   ├── app
        │   │   └── vifm-app.txt
        │   ├── plugin
        │   │   └── vifm-plugin.txt
        │   └── tags
        ├── ftdetect
        │   ├── vifm-rename.vim
        │   └── vifm.vim
        ├── ftplugin
        │   ├── mail_vifm.vim
        │   ├── vifm-cmdedit.vim
        │   ├── vifm-edit.vim
        │   ├── vifm-rename.vim
        │   └── vifm.vim
        ├── plugin
        │   └── vifm.vim
        └── syntax
            └── vifm.vim

12 directories, 15 files

$ cd .vim/plugged/vifm.vim/
$ git rev-parse HEAD
c48e06cd4bd2fe6340f9438cab93f34bb93115a7

When i execute ":EditVifm" under vim, after quit it, we see than some messages was displayed in background :

$ vim
vifm usage:

  To start in a specific directory give the directory path.

    vifm /path/to/start/dir/one
    or
    vifm /path/to/start/dir/one  /path/to/start/dir/two

  To open file using associated program pass to vifm it's path.

  To select file prepend its path with --select.

  If no path is given vifm will start in the current working directory.

  vifm --logging
    log some errors to ~/.vifm/log.

  vifm -c <command> | +<command>
    run <command> on startup.

  vifm --version | -v
    show version number and quit.

  vifm --help | -h
    show this help message and quit.

  vifm --no-configs
    don't read vifmrc and vifminfo.

any insights ?

Regards,

xaizek commented 6 years ago

Hello,

Your vifm version is much older than the plugin. Options that vifm.vim now passes to vifm were added right after 0.7.8, so you can't use plugin newer than that. You can see plugin version that matches 0.7.8 of vifm here and download it as a zip here.

rockandska commented 6 years ago

Thanks for your fast answer. It seems ok with ":EditVifm" on commit you point me at. With the others commands, i hit :

E492: Not an editor command: SplitVifm
E492: Not an editor command: VsplitVifm
E492: Not an editor command: VsplitVifm
E492: Not an editor command: DiffVifm
E492: Not an editor command: TabVifm

I suppose this is related to my version of vifm too ?

regards,

rockandska commented 6 years ago

My mistake, it is related to my vim-plug configuration.