Skip to content

⬆️ Update dependency JohnnyMorganz/StyLua to v2#58

Open
renovate[bot] wants to merge 1 commit intomainfrom
renovate/johnnymorganz-stylua-2.x
Open

⬆️ Update dependency JohnnyMorganz/StyLua to v2#58
renovate[bot] wants to merge 1 commit intomainfrom
renovate/johnnymorganz-stylua-2.x

Conversation

@renovate
Copy link
Contributor

@renovate renovate bot commented Nov 17, 2024

This PR contains the following updates:

Package Update Change
JohnnyMorganz/StyLua major 0.20.02.4.0

Release Notes

JohnnyMorganz/StyLua (JohnnyMorganz/StyLua)

v2.4.0

Compare Source

Added
  • Added flag --no-ignore-vcs to continue formatting files listed in a .gitignore file, instead of skipping over them (#​895)
  • Support call_parentheses = Input in editorconfig (#​1057)
  • Luau: Support formatting explicit type instantiations (f<<T>>(), obj:method<<T>>())
  • Support stylua_syntax and stylua_block_newline_gaps properties in editorconfig (#​1054)
Fixed
  • Fixed syntax error in output when a single-line comment appears between an index suffix and a table call argument, e.g. foo.bar -- comment { } (#​873)
  • Fixed malformed formatting when a binary expression inside of a function call with comments around the operators is incorrectly collapsed onto one line (#​996)
  • Fixed repeated unary minus on long lines being collapsed into a comment, e.g. - - - - -5 becoming -----5 (#​1075)
  • Fixed --preserve-block-newline-gaps CLI flag not being applied as a config override
  • Fixed LSP not respecting .stylua.toml on Windows due to incorrect file URI to path conversion (#​1051)

v2.3.1

Compare Source

Fixed
  • Use character-wised diff instead of byte-wise diff in the LSP server so that it can handle multi-byte characters (#​1042, #​1043).

v2.3.0

Compare Source

Added
  • The language server has an initialization option called respect_editor_formatting_options.
    If it's true, the formatting handler will override the configurations indent-width and indent-type with values from FormattingOptions
Changed
  • In language server mode, compute the difference between the unformatted and formatted document and only respond with the changes, rather than sending an edit for the whole file
  • Include serverInfo in the language server's InitializeResponse
Fixed
  • Fixed comments lost from expression after parentheses are removed when we are attempting to "hang" the expression. (#​1033)
  • Fixed document_range_formatting_provider capability missing from ServerCapabilities in language server mode
  • Fixed current working directory incorrectly used as config search root in language server mode -- now, the root of the opened workspace is used instead (#​1032)
  • Language server mode now correctly respects .styluaignore files (#​1035)
  • Luau: Fixed parentheses incorrectly removed on a single type that is the default for a variadic generic parameter (#​1038)

v2.2.0

Compare Source

Added
  • Added option block_newline_gaps to determine whether newline gaps at the start / end of blocks should be preserved. Defaults to Never, which is the original behaviour. (#​857)
  • StyLua can now run in a language server mode. Start StyLua with stylua --lsp and connect with a language client. (#​936)
Changed
  • Luau: Improved union of tables formatting to hang the union type rather than attempt to hug all the tables together (#​958)
Fixed
  • Fixed formatting of index containing brackets string in parentheses (#​992)
  • Fixed goto not being recognised for LuaJIT (#​986)
  • Fixed semicolon removed after a statement ending with an if-expression leading to ambiguous syntax when the next line begins with parentheses (#​1010)
  • Luau: Fixed malformed formatting when there is a comment after a type specifier in a local assignment (#​995)
  • Luau: Fixed long type union formatted onto a single line if there is a comment in between the equals sign and the type union in a type declaration (#​1007)
  • Fixed StyLua installation via pip / uv for Windows (#​1018)

v2.1.0

Compare Source

Added
  • Luau: Added support for parsing user-defined type functions (#​938)
  • Luau: Added support for parsing attributes (@native / @deprecated) on functions
  • Added support for CfxLua (FiveM) syntax formatting. This is available with syntax = "cfxlua" (#​855)
  • Added a pre-built binary release for stylua-linux-aarch64-musl.zip
  • Added error hints on parse failurse when a potential Lua syntax conflict is noticed (e.g., Lua 5.2 vs Luau syntax for labels :: and generics >>) (#​960 / #​962)
Changed
  • Updated StyLua release GitHub action to ubuntu-22.04 workers due to GitHub's deprecation of ubuntu-20.04. This may mean the pre-built release artifacts published to GitHub no longer work on ubuntu-20.04 and require a manual build.
Fixed
  • Luau: fixed parentheses incorrectly removed in (expr :: assertion) < foo when multilining the expression, leading to a syntax error (#​940)
  • Fixed panic when attempting to format a file outside of the current working directory when --respect-ignores is enabled (#​969)
  • Fixed unnecessary semicolons being introduced at the end of statements when incorrectly determined as ambiguous (#​963)
  • Fixed malformed formatting of function calls where parentheses are removed but there are comments in between the parentheses and the expression. Now, we will keep the parentheses in these cases, except for trailing comments (#​964)
  • Fixed malformed formatting of table field expression when there are comments in between the equals and the value (#​942)

v2.0.2

Compare Source

Fixed
  • Fixed regression where configuration present in current working directory not used when formatting from stdin and no --stdin-filepath is provided (#​928)
  • Luau: fixed incorrect indentation for leading token in union / intersection when hanging (#​932)

v2.0.1

Compare Source

Added
  • Verbose mode will now show resolved options
Fixed
  • Fixed CLI overrides not applying on top of a resolved stylua.toml file (#​925)

v2.0.0

Compare Source

Breaking Changes
  • For automated downloaders: the legacy release artifacts stylua-win64.zip, stylua-linux.zip and stylua-macos.zip are no longer produced in GitHub releases, in favour of more specific names (e.g., stylua-windows-x86_64, stylua-linux-x86_64 and stylua-macos-x86_64).
  • --stdin-filepath no longer respects ignore files by default, in line with passing files directly to the command line. Now, stylua --stdin-filepath foo.lua - will still format the stdin even if foo.lua was in a .styluaignore file. Use --respect-ignores to preserve the original behaviour.
  • Removed deprecated access patterns on Config struct in stylua Rust library
Added
  • Added runtime syntax configuration option syntax to help handle ambiguous syntax. By default, StyLua builds and runs with a parser to handle all Lua versions. However, the syntax of some Lua versions conflict with eachother: most notably, Lua 5.2+ goto label syntax ::label:: and Luau type assertion operator ::. This option allows choosing what syntax to parse, to handle these conflicts. (#​407)
  • Added configuration option space_after_function_names to specify whether to include a space between a function name and parentheses (#​839)
Changed
  • Update internal Lua parser version (full-moon) to v1.1.0. This includes parser performance improvements. (#​854)
  • LuaJIT is now separated from Lua52, and is available in its own feature and syntax flag
  • .stylua.toml config resolution now supports looking up config files next to files being formatted, recursively going
    upwards until reaching the current working directory, then stopping (unless --search-parent-directories was specified).
    For example, for a file ./src/test.lua, executing stylua src/ will look for ./src/stylua.toml and then ./stylua.toml.
  • When collapse_simple_statement is enabled, if the enclosing block is a return, we will check if the return expression is "simple" (currently, not containing a function definition) (#​898)
Fixed
  • Fixed formatting of method call chain when there is a comment between the colon token : and the function name (#​890)
  • Removed accidental random print to stdout when formatting a return statement across multiple lines (#​879)
  • Luau: Fixed incorrect removal of semicolon before compound assignment with parentheses leading to ambiguous syntax error (#​885)
  • Luau: Fixed incorrect collapsing of union/intersection type value with comments in a type table leading to a syntax error (#​893)
  • Fixed --verify panicing due to overflow for very large Hex numbers (#​875, #​889)

Configuration

📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this PR and you won't be reminded about this update again.


  • If you want to rebase/retry this PR, check this box

This PR was generated by Mend Renovate. View the repository job log.

@renovate renovate bot force-pushed the renovate/johnnymorganz-stylua-2.x branch from 26583ce to 62d72ad Compare November 18, 2024 23:19
@renovate renovate bot force-pushed the renovate/johnnymorganz-stylua-2.x branch from 62d72ad to 5d50471 Compare December 7, 2024 16:52
@renovate renovate bot force-pushed the renovate/johnnymorganz-stylua-2.x branch from 5d50471 to 98d5a82 Compare April 21, 2025 19:22
@renovate renovate bot force-pushed the renovate/johnnymorganz-stylua-2.x branch from 98d5a82 to a933b38 Compare September 14, 2025 20:27
@renovate renovate bot force-pushed the renovate/johnnymorganz-stylua-2.x branch from a933b38 to f1a9b88 Compare September 27, 2025 13:31
@renovate renovate bot force-pushed the renovate/johnnymorganz-stylua-2.x branch from f1a9b88 to 4c05854 Compare November 1, 2025 18:38
@renovate renovate bot force-pushed the renovate/johnnymorganz-stylua-2.x branch from 4c05854 to 4903546 Compare February 2, 2026 18:11
@renovate renovate bot force-pushed the renovate/johnnymorganz-stylua-2.x branch from 4903546 to 17c866e Compare March 7, 2026 17:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants