Giter Club home page Giter Club logo

Comments (5)

kevinoid avatar kevinoid commented on June 28, 2024

Thanks for reporting the issue. Unfortunately, I'm unable to reproduce it. What version of Neovim are you using? Can you reproduce the issue without vim-plug?

from vim-jsonc.

gasull avatar gasull commented on June 28, 2024

What version of Neovim are you using?

$ nvim --version
NVIM v0.4.4
Build type: Release
LuaJIT 2.1.0-beta3
Compilation: /usr/bin/cc -g -O2 -fdebug-prefix-map=/build/neovim-eK2ojg/neovim-0.4.4=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=1 -DDISABLE_LOG -Wdate-time -D_FORTIFY_SOURCE=1 -O2 -DNDEBUG -DMIN_LOG_LEVEL=3 -Wall -Wextra -pedantic -Wno-unused-parameter -Wstrict-prototypes -std=gnu99 -Wshadow -Wconversion -Wmissing-prototypes -Wimplicit-fallthrough -Wvla -fstack-protector-strong -fno-common -fdiagnostics-color=always -DINCLUDE_GENERATED_DECLARATIONS -D_GNU_SOURCE -DNVIM_MSGPACK_HAS_FLOAT32 -DNVIM_UNIBI_HAS_VAR_FROM -I/build/neovim-eK2ojg/neovim-0.4.4/build/config -I/build/neovim-eK2ojg/neovim-0.4.4/src -I/usr/include -I/usr/include/lua5.1 -I/build/neovim-eK2ojg/neovim-0.4.4/build/src/nvim/auto -I/build/neovim-eK2ojg/neovim-0.4.4/build/include
Compiled by [email protected]

Features: +acl +iconv +tui
See ":help feature-compile"

   system vimrc file: "$VIM/sysinit.vim"
  fall-back for $VIM: "/usr/share/nvim"

Run :checkhealth for more info

Can you reproduce the issue without vim-plug?

I haven't tried without vim-plug because I find it very cumbersome to manage plugins without it. I did reduce my /etc/xdg/nvim/sysinit.vim to the minimum and it still happens:

" vim-plug
" From https://github.com/junegunn/vim-plug/wiki/tips#automatic-installation
" Automatic installation
if empty(glob('~/.local/share/nvim/site/autoload/plug.vim'))
  silent !curl -fLo ~/.local/share/nvim/site/autoload/plug.vim --create-dirs
    \ https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim
  autocmd VimEnter * PlugInstall --sync | source $MYVIMRC
  " ~/.cache grows really big
  silent !rm -rf ~/.cache
  autocmd VimEnter * UpdateRemotePlugins
endif
" Plugins will be downloaded under the specified directory.
call plug#begin('~/.vim/plugged')
" Declare the list of plugins.
Plug 'kevinoid/vim-jsonc'
call plug#end()

I'm able to edit other (non json) files without a problem.

from vim-jsonc.

djvolz avatar djvolz commented on June 28, 2024

I'm seeing the same issue using vim-plug on nvim v0.4.4.

from vim-jsonc.

rockyzhang24 avatar rockyzhang24 commented on June 28, 2024

Same here.

❯ nvim --version
NVIM v0.5.0-dev+4d1fc167a
Build type: Release
LuaJIT 2.1.0-beta3
Compilation: /usr/bin/clang -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=1 -DNDEBUG -Wall -Wextra -pedantic -Wno-unused-parameter -Wstrict-prototypes -std=gnu99 -Wshadow -Wconversion -Wmissing-prototypes -Wimplicit-fallthrough -Wvla -fstack-protector-strong -fno-common -fdiagnostics-color=auto -DINCLUDE_GENERATED_DECLARATIONS -D_GNU_SOURCE -DNVIM_MSGPACK_HAS_FLOAT32 -DNVIM_UNIBI_HAS_VAR_FROM -DMIN_LOG_LEVEL=3 -I/tmp/neovim-20210126-11253-b8ucul/build/config -I/tmp/neovim-20210126-11253-b8ucul/src -I/usr/local/include -I/tmp/neovim-20210126-11253-b8ucul/deps-build/include -I/opt/local/include -I/tmp/neovim-20210126-11253-b8ucul/build/src/nvim/auto -I/tmp/neovim-20210126-11253-b8ucul/build/include
Compiled by yanzhang@mbp

Features: +acl +iconv +tui
See ":help feature-compile"

   system vimrc file: "$VIM/sysinit.vim"
  fall-back for $VIM: "/usr/local/Cellar/neovim/HEAD-4d1fc16/share/nvim"

Run :checkhealth for more info

@gasull @djvolz , I found an alternative (https://github.com/neoclide/jsonc.vim) and it works well.
Thanks.

from vim-jsonc.

zhmars avatar zhmars commented on June 28, 2024

To Reproduce

  • Run vim --clean minimal.jsonc with
// minimal.jsonc
{
  "foo": "bar"
}
  • Run command :setfiletype jsonc

from vim-jsonc.

Related Issues (7)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.