-
Notifications
You must be signed in to change notification settings - Fork 331
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ci: consistently enforce Lua coding style #1029
Conversation
Hmm, looks like lua 5.4 is not picked up correctly. I will investigate. |
The formatting is failing because, as I have now learned, stylua does not support This can be solved (at least) the following ways:
What would you prefer? My favorite options are 2, 7, and 3. |
I think we can simply ignore it, i.e. |
376d1f4
to
fe967c8
Compare
This commit adds a GitHub Actions workflow that checks the lua files against the yazi lua coding style. The workflow uses the `stylua` tool, which can be installed using cargo: ```sh cargo install stylua --features lua54 ``` I picked the options for the formatter in a way that forced minimal changes to the existing style. <https://github.com/JohnnyMorganz/StyLua?tab=readme-ov-file#options> Update .github/workflows/check.yml Co-authored-by: 三咲雅 · Misaki Masa <sxyazi@gmail.com>
3947b28
to
b8264fc
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!
This commit adds a GitHub Actions workflow that checks the lua files against the yazi lua coding style.
The workflow uses the
stylua
tool, which can be installed using cargo:I picked the options for the formatter in a way that forced minimal changes to the existing style.
https://github.com/JohnnyMorganz/StyLua?tab=readme-ov-file#options