Closed nikekukuri closed 1 month ago
LuaSnipが動かない
以下をhelpより参照する To apply Variable/Placeholder-transformations https://code.visualstudio.com/docs/editor/userdefinedsnippets#_variable-transforms, luasnip needs to apply ECMAScript regexes. This is implemented by relying on jsregexp https://github.com/kmarius/jsregexp.
jsregexp
The easiest (but potentially error-prone) way to install it is by calling make install_jsregexp in the repo root.
make install_jsregexp
This process can be automated by packer.nvim:
packer.nvim
lua use { "L3MON4D3/LuaSnip", run = "make install_jsregexp" } <
If this fails, first open an issue :P, and then try installing the jsregexp-luarock. This is also possible via packer.nvim, although actual usage may require a small workaround, see here https://github.com/wbthomason/packer.nvim/issues/593 or here https://github.com/wbthomason/packer.nvim/issues/358.
Alternatively, jsregexp can be cloned locally, maked, and the resulting jsregexp.so placed in some place where nvim can find it (probably ~/.config/nvim/lua/).
make
jsregexp.so
~/.config/nvim/lua/
If jsregexp is not available, transformations are replaced by a simple copy.
ギブ
LuaSnipが動かない
以下をhelpより参照する To apply Variable/Placeholder-transformations https://code.visualstudio.com/docs/editor/userdefinedsnippets#_variable-transforms, luasnip needs to apply ECMAScript regexes. This is implemented by relying on
jsregexp
https://github.com/kmarius/jsregexp.The easiest (but potentially error-prone) way to install it is by calling
make install_jsregexp
in the repo root.This process can be automated by
packer.nvim
:If this fails, first open an issue :P, and then try installing the
jsregexp
-luarock. This is also possible viapacker.nvim
, although actual usage may require a small workaround, see here https://github.com/wbthomason/packer.nvim/issues/593 or here https://github.com/wbthomason/packer.nvim/issues/358.Alternatively,
jsregexp
can be cloned locally,make
d, and the resultingjsregexp.so
placed in some place where nvim can find it (probably~/.config/nvim/lua/
).If
jsregexp
is not available, transformations are replaced by a simple copy.