Skip to content

fix: Change initialization order #10

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

Merged
merged 1 commit into from
Oct 11, 2022
Merged

fix: Change initialization order #10

merged 1 commit into from
Oct 11, 2022

Conversation

tani
Copy link
Contributor

@tani tani commented Oct 11, 2022

Closes #7. This PR moves the single line from L27 to L57.
L27 executed runtime plugin/tsdetect.vim . Then, Vim runs the auto command User tsdetect#detect. However, before L27, Vim has not defined such auto commands. In fact, the function initialize() first defined those auto commands. By moving it to L57, Vim throws no errors mentioned in #7. It seems no problem because there are no suspicious codes between L27 to L57 (there are only the registration commands for Coc.nvim). I hope that it works well.

@LumaKernel LumaKernel changed the title Change initialization order fix: Change initialization order Oct 11, 2022
@LumaKernel LumaKernel merged commit edd4ebc into LumaKernel:main Oct 11, 2022
@github-actions
Copy link

🎉 This PR is included in version 4.0.2 🎉

The release is available on:

Your semantic-release bot 📦🚀

tani added a commit to tani/vim-tsdetect that referenced this pull request Oct 12, 2022
LumaKernel pushed a commit that referenced this pull request Oct 12, 2022
* Change initialization order

* Suppress autocmds errors

* Suppress tsdetect#coc#auto#switch#*#after

* Revert #10

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

Successfully merging this pull request may close these issues.

After installing, I see "No matching autocommands: User tsdetect#detect#node"
2 participants