LuaSnip
LuaSnip copied to clipboard
What is the next step after installing jsregexp using luarocks?
I am windows 10 user.
I failed to link jsregexp.so using gcc. gcc cannot recognize the libraries, -L options doesn't work
Anyway, For alternative method, I install jsregexp using luarocks
Although I installed jsregexp, :checkhealth LuaSnip cannot recognize jsregexp library
:lua =require('luasnip.util.util).jsregexp output is nil still as you said in #986
Could you notice some guide after installing jsregexp using luarocks?
It's possible that jsregexp is installed for the wrong lua-version, could you check your :version, especially which lua-version it references? For me, for example it's LuaJIT.
I'm sure the lua-version can be adjusted somehow for luarocks :)
@L3MON4D3
Ok.. I tried to install lua 5.1 version and jsregexp, but it failed. I'll check other way installing possible. Thanks
Botherd me a few days, finally, I find a solution to this.
It's possible that jsregexp is installed for the wrong lua-version, could you check your
:version, especially which lua-version it references? For me, for example it'sLuaJIT. I'm sure the lua-version can be adjusted somehow for luarocks :)
Exactly, we should match the installed lua version to take effect. the easiest way to do this is through install DEVCOM.LuaJIT by winget:
winget install DEVCOM.LuaJIT
In which the lua used by luarocks is version 5.1, and then use luarocks to install jsregexp:
luarocks install jsregexp 0.0.5-1
finally, jsregexp will take effect on luasnip windows.🥳
If you are still having problems with jsregexp - https://github.com/L3MON4D3/LuaSnip/issues/986#issuecomment-2425313904 or check other comments in that issue