oni2
oni2 copied to clipboard
Error using bracket pair colorizer 2
I am unable to use Bracket Pair Colorizer 2, I was able to install Bracket Pair Colorizer without errors but it didn't work.
This seems like it should be related to themes, if not maybe there should be an update to VSCode Extension Host Integration?
[DEBUG] +0ms Revery.FontCache : Resolving fallback for: Error: Activating extension 'CoenraadS.bracket-pair-colorizer-2' failed: Cannot find module '/tmp/.mount_oni2to7QdG/usr/bin/node_modules.asar/vscode-textmate'
Require stack:
- /home/doc/.config/oni2/extensions/CoenraadS.bracket-pair-colorizer-2-0.2.0/out/src/textMateLoader.js
- /home/doc/.config/oni2/extensions/CoenraadS.bracket-pair-colorizer-2-0.2.0/out/src/settings.js
- /home/doc/.config/oni2/extensions/CoenraadS.bracket-pair-colorizer-2-0.2.0/out/src/documentDecorationManager.js
- /home/doc/.config/oni2/extensions/CoenraadS.bracket-pair-colorizer-2-0.2.0/out/src/extension.js
- /tmp/.mount_oni2to7QdG/usr/share/node/node_modules/@onivim/vscode-exthost/out/vs/loader.js
- /tmp/.mount_oni2to7QdG/usr/share/node/node_modules/@onivim/vscode-exthost/out/bootstrap-amd.js
- /tmp/.mount_oni2to7QdG/usr/share/node/node_modules/@onivim/vscode-exthost/out/bootstrap-fork.js. at byte offset 487
OS: Arch Linux Version: 0.5.1-nightly
Indent-Rainbow also successfully installs but does not work. I think this is related to the issues with Bracket Pair Colorizer.
Interesting, thanks for sharing the log @Th3Whit3Wolf !
It looks like Bracket Pair Colorizer 2 actually looks at the internals of VSCode to pick the oniguruma and textmate node_modules - we might need to bundle those (and make sure the appRoot is set appropriately): https://github.com/CoenraadS/Bracket-Pair-Colorizer-2/blob/f4f5bf2795a2d4c81d4d423deca6af3533a30ff7/src/textMateLoader.ts
Past that, both the APIs use a decorations API that we don't support, yet - so we need to support this textEditor.setDecorations API: https://github.com/CoenraadS/Bracket-Pair-Colorizer-2/blob/6ab0a5656d97b1f86fb9c5b0405072aabd252990/src/documentDecoration.ts#L210
The author of the bracket colorizer seems to have discontinued support - both bracket colorizer 1 and 2 GitHub repos are archived.
Any hope that Oni2 could support it natively? (This is also the direction VSC is taking, native rather than extension support).
Really missing this in my daily life - this kind of colorizer stuff for 'brackets', 'code block extent gutter indication', etc, would save a lot of pain in daily life. Hope it comes natively some day :) .