LuaLS / LLS-Addons

Addons for use with Sumneko's Lua Language Server
https://github.com/LuaLS/lua-language-server
MIT License
63 stars 46 forks source link

Added libyue definitions #37

Closed Frityet closed 1 year ago

Frityet commented 1 year ago

Libyue is a GUI library for C++, JS, and Lua. On the GitHub page, there is a set of .json files which define the Yue API. The autogen.lua file automatically turns that into CATS definitions.

carsakiller commented 1 year ago

Hello 👋

Can you please create a separate branch that excludes the generation code and other unnecessary files and then update the submodule?

Josef-Friedrich commented 1 year ago

Any progress?

Frityet commented 1 year ago

Hello 👋

Can you please create a separate branch that excludes the generation code and other unnecessary files and then update the submodule?

What do you mean by this?

Frityet commented 1 year ago

Any progress?

Just read this 😅

carsakiller commented 1 year ago

There are a lot of files that should not be included as part of the addon image Also, the definitions must be in a “library” folder, so you will have to move the “yue” folder into a “library” folder. Check one of the already included addons to see what sort of structure is required.

Frityet commented 1 year ago

There are a lot of files that should not be included as part of the addon image Also, the definitions must be in a “library” folder, so you will have to move the “yue” folder into a “library” folder. Check one of the already included addons to see what sort of structure is required.

Will do, thanks!

Frityet commented 1 year ago

Done 👍

carsakiller commented 1 year ago

Please run StyLua to apply the proper code style.

Frityet commented 1 year ago

Please run StyLua to apply the proper code style.

Stylua fails because some argument names are also lua keywords, i.e end. Should I change this? It works fine on lualanguageserver

Josef-Friedrich commented 1 year ago

How about https://github.com/JohnnyMorganz/StyLua#ignoring-parts-of-a-file ?

Frityet commented 1 year ago

How about JohnnyMorganz/StyLua#ignoring-parts-of-a-file ?

im just gonna have automatic keyword -> _keyword so like, end would become _end

carsakiller commented 1 year ago

Is using end not a syntax error? Any time I have mistakenly used end, I receive a syntax error.

Frityet commented 1 year ago

Is using end not a syntax error? Any time I have mistakenly used end, I receive a syntax error.

it is, however lua-language-server doesn't care for meta files

Frityet commented 1 year ago

Anyways, fixed, im gonna make an API update and then push