editorconfig-vim icon indicating copy to clipboard operation
editorconfig-vim copied to clipboard

Does it work with nvim?

Open stepancheg opened this issue 3 years ago • 7 comments

I see from issues, it is supposed to work with NeoVim. Can you clarify it in readme?

stepancheg avatar Jan 21 '21 17:01 stepancheg

It works normally in neovim, even in android with termux it also works fine :), although I have only used the supported properties that are in the README

GiancarloAparicio avatar Feb 25 '21 15:02 GiancarloAparicio

@stepancheg I would welcome a PR to update the README :)

cxw42 avatar Feb 25 '21 18:02 cxw42

Well using neovim 0.6.0 it seems to load and set the autocmd but it dosn't seem to work .. like the load is done before the default of nvim. I haven't figured it out yet but it seems that it broke when 0.6.0 was released.

Anyhow once reloaded it works fine so

augroup _editorconfig
autocmd BufEnter * :EditorConfigReload
augroup END

does the trick for me

desdic avatar Dec 03 '21 21:12 desdic

I have the same problem here. I am not very proficient at vimscript, but the plugin tries to do it here.

# https://github.com/editorconfig/editorconfig-vim/blob/master/plugin/editorconfig.vim#L259
function! s:EditorConfigEnable(should_enable)
    augroup editorconfig
        autocmd!
        if a:should_enable
            autocmd BufNewFile,BufReadPost,BufFilePost * call s:UseConfigFiles()
        endif
    augroup END
endfunction

@desdic's trick works for me.

twnaing avatar Dec 06 '21 12:12 twnaing

Quack,

I just installed the plugin on neovim 0.6.0-1 (on Debian unstable) and tested with a project with different settings for different extensions (especially different indent_style/indent_size) and it is working fine without any trick. I use vim-plug and the plugin iis loaded quite early after theming plugins and before anything else. I only set g:EditorConfig_exclude_patterns for fugitive/scp as recommended.

\_o<

duck-rh avatar Dec 24 '21 06:12 duck-rh

For me, it used to work. Using Neovim 0.7.2 it does not any more. Switched over to https://github.com/gpanders/editorconfig.nvim, works out of the box, no config. It has less configurability but I just need a simple plugin that works. Maybe interesting to someone else as well.

herrbischoff avatar Aug 01 '22 17:08 herrbischoff

FYI: gpanders/editorconfig.nvim has been merged into NeoVim 0.9. See: https://github.com/neovim/neovim/pull/21633

nyngwang avatar Jan 17 '23 21:01 nyngwang