Closed shadmansaleh closed 2 years ago
Thanks for the quick patch . By the way do you know how to update the parser to master ? TSUpdate doesn't seem to want to make an update happen ;]
Hm, it works for me. You could always just try to :TSUninstall
and install again...
The parsers are locked in nvim-treesitter; there's an automated CI action that bumps the versions: https://github.com/nvim-treesitter/nvim-treesitter/blob/master/.github/workflows/update-parsers-pr.yml
So you'll have to wait until that picks up the updates to this parser (nvim-treesitter master gets a push) and gets merged. ~Alternative is :TSInstallFromGrammar
, which also pulls the tip of the repo, I believe.~
EDIT Nope; best way is to clone the repo and use the local copy as a new parser source.
Oh I didn't know thank you.
Or, probably easiest, just edit the lockfile.json locally and remove the revision
key; that should make it TSInstall
from the corresponding master
.
@clason thanks for the info. But what's the purpose of the lock? The CI updates the lockfile with commit id from master I can't see why update can't directly happen from master . If ref is set to specific tag/commit then the lock makes sense but when the ref is master does the lock add any benefit ?
The ref is indeed set to a specific commit, but only if nvim-treesitter CI passes; otherwise the revision is not updated. This ensures that nvim-treesitter never installs a (known) broken parser.
Thanks now that makes sense :)
And we know that our queries are still compatible. The queries have to be always up-to-date with the parser when the grammar changes.
If two consecutive lines have images the parser fails.
Example
ast from TSPlayground
But if new_line between the images is removed or additional line is added between the two images the parser works .
Means this works but the above one doesn't