Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Plugins not properly functioning on fresh install until "PackerSync" is run and treesitter runs background update. #72

Closed
MarcPaquette opened this issue Nov 12, 2021 · 2 comments

Comments

@MarcPaquette
Copy link

Reproduction steps:

clone_if_not_exist "https://github.com/luan/nvim.git" "${HOME}/.config/nvim"

# Add custom Nvim config
echo "Symlinking nvim config"
rm -f "${HOME}/.config/nvim/lua/user/after.lua" "${HOME}/.config/nvim/lua/user/plugins.lua" "${HOME}/.config/nvim/lua/user/before.lua"
mkdir -p "${HOME}"/.config/nvim/lua/user
ln -sf "${DIR}/nvim-after.lua" "${HOME}/.config/nvim/lua/user/after.lua"
ln -sf "${DIR}/nvim-plugins.lua" "${HOME}/.config/nvim/lua/user/plugins.lua"
ln -sf "${DIR}/nvim-before.lua" "${HOME}/.config/nvim/lua/user/before.lua"

# Update all the plugins
nvim +UpdateRemotePlugins +qall
nvim -c 'autocmd User PackerComplete quitall' -c 'PackerSync'

At this point the plugins are partially working, but opening up a tree navigator - results in an error:
image

It's not until a :PackerSync is manually invoked does the treesitter begin to get updated as a background process.
image
Note "60/70" in bottom left corner indicating an update is occurring even after the :PackerSync is finished.

@luan
Copy link
Owner

luan commented Nov 21, 2021

I was able to reproduce this. And got around the problem with a nvim -c 'TSInstallSync all' -c 'qall'

Can you try that and see if it fixes it for you too?

@MarcPaquette
Copy link
Author

nvim --headless -c 'TSInstallSync all' -c 'qall' fixes it. When using it without the headless it causes nvim to kick in with a pager of some kind.

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants