SHA256
12
0
forked from pool/StyLua

44 Commits

Author SHA256 Message Date
508580a405 Accepting request 1230949 from devel:languages:lua
- Update to version 2.0.2:
  * Fixed regression where configuration present in current working directory
    not used when formatting from stdin and no --stdin-filepath is provided
  * Luau: fixed incorrect indentation for leading token in union / intersection
    when hanging
  * Verbose mode will now show resolved options
  * Fixed CLI overrides not applying on top of a resolved stylua.toml file
  * 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 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 :🏷️: and Luau type assertion
    operator ::. This option allows choosing what syntax to parse, to handle
    these conflicts.
  * Added configuration option space_after_function_names to specify whether
    to include a space between a function name and parentheses
  * Update internal Lua parser version (full-moon) to v1.1.0. This includes
    parser performance improvements.
  * 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

OBS-URL: https://build.opensuse.org/request/show/1230949
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/StyLua?expand=0&rev=16
2024-12-15 11:37:37 +00:00
Soc Virnyl Estela
216825cbee - Update to version 2.0.2:
* Fixed regression where configuration present in current working directory
    not used when formatting from stdin and no --stdin-filepath is provided
  * Luau: fixed incorrect indentation for leading token in union / intersection
    when hanging
  * Verbose mode will now show resolved options
  * Fixed CLI overrides not applying on top of a resolved stylua.toml file
  * 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 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 :🏷️: and Luau type assertion
    operator ::. This option allows choosing what syntax to parse, to handle
    these conflicts.
  * Added configuration option space_after_function_names to specify whether
    to include a space between a function name and parentheses
  * Update internal Lua parser version (full-moon) to v1.1.0. This includes
    parser performance improvements.
  * 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

OBS-URL: https://build.opensuse.org/package/show/devel:languages:lua/StyLua?expand=0&rev=43
2024-12-14 01:06:10 +00:00
be0a584abf Accepting request 1155393 from devel:languages:lua
- BuildRequires should be cargo and not rust+cargo
  * a known issue is causing some broken builds e.g. providing a lower version
- Reenable cargo tests.

OBS-URL: https://build.opensuse.org/request/show/1155393
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/StyLua?expand=0&rev=15
2024-03-06 22:05:09 +00:00
Soc Virnyl Estela
f406ee67d0 - BuildRequires should be cargo and not rust+cargo
* a known issue is causing some broken builds e.g. providing a lower version

OBS-URL: https://build.opensuse.org/package/show/devel:languages:lua/StyLua?expand=0&rev=41
2024-03-06 02:08:22 +00:00
Soc Virnyl Estela
1ffff13ad5 Accepting request 1155391 from home:uncomfyhalomacro:branches:devel:languages:lua
- Reenable cargo tests.

OBS-URL: https://build.opensuse.org/request/show/1155391
OBS-URL: https://build.opensuse.org/package/show/devel:languages:lua/StyLua?expand=0&rev=40
2024-03-06 02:05:47 +00:00
bee6ec96d4 Accepting request 1154478 from devel:languages:lua
OBS-URL: https://build.opensuse.org/request/show/1154478
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/StyLua?expand=0&rev=14
2024-03-04 20:25:06 +00:00
Soc Virnyl Estela
c8fe55bfe1 Accepting request 1154441 from home:amanzini:branches:devel:languages:lua
- Update to version 0.20.0:
  ### Changed
  - Files excluded by git (via .gitignore or global git configuration), as well as in an .ignore file 
    (used by ripgrep and The Silver Searcher) will now also be ignored by StyLua 
    (as if they were all .styluaignore files).
  ### Fixed
  * General
  - The CLI tool will now only write files if the contents differ, and not modify the file if there 
    is no change after formatting 
  - Fixed function body parentheses being placed on multiple lines unnecessarily when there are no parameters
  - Fixed directory paths w/o globs in .styluaignore not matching when using --respect-ignores
  * Luau
  - Fixed handling of floor division (//) syntax when only Luau command line flag is enabled
  - Fixed missing space when table is inside of Luau interpolated string expression ({{ is invalid syntax)
  - Fixed parentheses around a Luau compound type inside of a type table indexer being removed causing a syntax error

OBS-URL: https://build.opensuse.org/request/show/1154441
OBS-URL: https://build.opensuse.org/package/show/devel:languages:lua/StyLua?expand=0&rev=38
2024-03-04 02:36:39 +00:00
f37064fbc0 Accepting request 1127596 from devel:languages:lua
Automatic submission by obs-autosubmit

OBS-URL: https://build.opensuse.org/request/show/1127596
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/StyLua?expand=0&rev=13
2023-11-20 20:19:44 +00:00
Soc Virnyl Estela
a7ab7e8bf4 - Update to version 0.19.0:
### Added
  - Added flag `--respect-ignores`. By default, files explicitly passed
  to stylua (e.g. `stylua foo.lua`) will always be formatted, regardless of
  whether the file is ignored. Enabling this flag will consider `.styluaignore`
  or glob matches before formatting the file.
  
    - Note: for backwards compatibility reasons, formatting via stdin always
    respects ignores. This behaviour will change in the next major release
  ### Changed
  - Updated parser crate with following changes:
    - Support Luau floor division (`//`)
    - Fix Luau string interpolation parsing
    - Fix Luau `\z` escape parsing
  - Simplified access and modification patterns for StyLua configuration. You
  can now access the properties directly
    - **Deprecated:** the old access patterns of `.property()` and
    `.with_property()` are now deprecated
    - **Breaking Change (WASM):** due to JS/TS lack of differentiation
    between `.property` / `.property()` implementation, the `.property()`
    functions were removed from WASM output.
  - Multiline comments before commas will now remain in place and not move
  to after the comma. This is to support type-assertions-via-comments that
  is commonly used by some language servers.

OBS-URL: https://build.opensuse.org/package/show/devel:languages:lua/StyLua?expand=0&rev=36
2023-11-12 14:00:12 +00:00
b2bb3e957a Accepting request 1118039 from devel:languages:lua
Automatic submission by obs-autosubmit

OBS-URL: https://build.opensuse.org/request/show/1118039
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/StyLua?expand=0&rev=12
2023-10-16 21:01:30 +00:00
Soc Virnyl Estela
64007b36d5 - Update to version 0.18.2:
* Fixed LuaJIT suffixes LL/ULL causing a panic when running in --verify mode
  * Fixed incorrect formatting of conditionals when collapse_simple_statement is enabled and the block begins with an empty line
  * Fixed formatting of dot function call chains with comment between dot and names

OBS-URL: https://build.opensuse.org/package/show/devel:languages:lua/StyLua?expand=0&rev=34
2023-10-09 13:18:51 +00:00
97a8c72cd5 Accepting request 1106048 from devel:languages:lua
- Update to version 0.18.1:
  * Fixed parentheses around a single Luau type pack in a generic being removed causing syntax errors.

OBS-URL: https://build.opensuse.org/request/show/1106048
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/StyLua?expand=0&rev=11
2023-08-28 15:14:44 +00:00
Soc Virnyl Estela
83303ccdb1 - Update to version 0.18.1:
* Fixed parentheses around a single Luau type pack in a generic being removed causing syntax errors.

OBS-URL: https://build.opensuse.org/package/show/devel:languages:lua/StyLua?expand=0&rev=32
2023-08-26 13:46:38 +00:00
33c7672dad Accepting request 1104907 from devel:languages:lua
Automatic submission by obs-autosubmit

OBS-URL: https://build.opensuse.org/request/show/1104907
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/StyLua?expand=0&rev=10
2023-08-21 09:45:11 +00:00
Soc Virnyl Estela
43e46a55ba Replace obsoleted disabled option with manual
OBS-URL: https://build.opensuse.org/package/show/devel:languages:lua/StyLua?expand=0&rev=30
2023-08-13 14:07:39 +00:00
b79a15915b Accepting request 1093613 from devel:languages:lua
- Update to version 0.18.0:
  * Multiline ignores (-- stylua: ignore start / -- stylua: ignore end) will now work within table fields
  * Added option "Input" to call_parentheses setting, where call parentheses are retained based on their presence in the original input code.
  * Improved heuristics around Luau type excess parentheses removal, so unnecessary parentheses around types are removed in more locations
  * Function calls are now formatted onto multiple lines if the opening brace { of a multiline table forces one of the lines over width
  * Fixed missing option --sort-requires to enable sort requires on the command line
  * Fixed parentheses removed around Luau optional type (B?) causing syntax errors when present in an intersection A & (B?)
  * Fixed comments lost when parentheses removed around Luau types
  * Fixed race condition where if a file is passed more than once as an argument to format, then it could potentially be wiped completely 
    (for example, if an ancestor directory is passed and recursively searched, as well as the file itself)

OBS-URL: https://build.opensuse.org/request/show/1093613
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/StyLua?expand=0&rev=9
2023-06-20 14:47:31 +00:00
Soc Virnyl Estela
f643962b64 - Update to version 0.18.0:
* Multiline ignores (-- stylua: ignore start / -- stylua: ignore end) will now work within table fields
  * Added option "Input" to call_parentheses setting, where call parentheses are retained based on their presence in the original input code.
  * Improved heuristics around Luau type excess parentheses removal, so unnecessary parentheses around types are removed in more locations
  * Function calls are now formatted onto multiple lines if the opening brace { of a multiline table forces one of the lines over width
  * Fixed missing option --sort-requires to enable sort requires on the command line
  * Fixed parentheses removed around Luau optional type (B?) causing syntax errors when present in an intersection A & (B?)
  * Fixed comments lost when parentheses removed around Luau types
  * Fixed race condition where if a file is passed more than once as an argument to format, then it could potentially be wiped completely 
    (for example, if an ancestor directory is passed and recursively searched, as well as the file itself)

OBS-URL: https://build.opensuse.org/package/show/devel:languages:lua/StyLua?expand=0&rev=28
2023-06-18 01:19:00 +00:00
25d0c4a240 Accepting request 1093484 from devel:languages:lua
Automatic submission by obs-autosubmit

OBS-URL: https://build.opensuse.org/request/show/1093484
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/StyLua?expand=0&rev=8
2023-06-16 14:55:57 +00:00
Soc Virnyl Estela
73d4860282 - Update to version 0.17.1
* Bumped internal parser dependency which should fix parsing problems for comments with Chinese characters, and multiline string escapes
  * Fixed comments in punctuated lists for return statements or assignments being incorrectly formatted leading to syntax errors
  * Fixed line endings not being correctly formatted in multiline string literals and comments

OBS-URL: https://build.opensuse.org/package/show/devel:languages:lua/StyLua?expand=0&rev=26
2023-06-09 11:43:12 +00:00
6da3acd4d0 Accepting request 1074821 from devel:languages:lua
Automatic submission by obs-autosubmit

OBS-URL: https://build.opensuse.org/request/show/1074821
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/StyLua?expand=0&rev=7
2023-03-28 15:50:34 +00:00
Soc Virnyl Estela
ab8d4f4c87 - Disable tests. Failing for editorconfig.
OBS-URL: https://build.opensuse.org/package/show/devel:languages:lua/StyLua?expand=0&rev=24
2023-03-21 04:38:24 +00:00
Soc Virnyl Estela
102e0d7356 OBS-URL: https://build.opensuse.org/package/show/devel:languages:lua/StyLua?expand=0&rev=23 2023-03-21 04:06:27 +00:00
Soc Virnyl Estela
4a8d73d90f - Remove editorconfig requirement.
- Fix tests.

OBS-URL: https://build.opensuse.org/package/show/devel:languages:lua/StyLua?expand=0&rev=22
2023-03-21 02:17:01 +00:00
Soc Virnyl Estela
a0b56b76df - Add editorconfig as build requirement.
OBS-URL: https://build.opensuse.org/package/show/devel:languages:lua/StyLua?expand=0&rev=21
2023-03-21 00:31:33 +00:00
Soc Virnyl Estela
eca42d6731 OBS-URL: https://build.opensuse.org/package/show/devel:languages:lua/StyLua?expand=0&rev=20 2023-03-21 00:27:44 +00:00
Soc Virnyl Estela
24659d57bd - Fix tests.
OBS-URL: https://build.opensuse.org/package/show/devel:languages:lua/StyLua?expand=0&rev=19
2023-03-21 00:25:18 +00:00
Soc Virnyl Estela
fcb337ae13 OBS-URL: https://build.opensuse.org/package/show/devel:languages:lua/StyLua?expand=0&rev=18 2023-03-19 13:17:02 +00:00
Soc Virnyl Estela
782c19f6b0 - Update to version 0.17.0:
* Sort requires
  * Add default editorconfig feature
  * extension: Pass cwd as workspace folder for version check
  * Add Dockerfile

OBS-URL: https://build.opensuse.org/package/show/devel:languages:lua/StyLua?expand=0&rev=17
2023-03-18 11:42:47 +00:00
07f69e521b Accepting request 1067592 from devel:languages:lua
Automatic submission by obs-autosubmit

OBS-URL: https://build.opensuse.org/request/show/1067592
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/StyLua?expand=0&rev=6
2023-02-24 17:08:24 +00:00
Soc Virnyl Estela
65ad2f6fc9 OBS-URL: https://build.opensuse.org/package/show/devel:languages:lua/StyLua?expand=0&rev=15 2023-02-17 11:16:59 +00:00
Soc Virnyl Estela
db8dbd0743 OBS-URL: https://build.opensuse.org/package/show/devel:languages:lua/StyLua?expand=0&rev=14 2023-02-17 11:13:29 +00:00
Soc Virnyl Estela
2c40cb4a1d - Update to version 0.16.1:
* General
    - Fixed mistransformation of a function argument in a multilined function call when the argument contains a comment, causing a syntax error. We now attempt to hang the expression (#648)
  * Luau
    - Fixed verify AST flagging a false positive for parentheses removed around a Luau type (#643)

OBS-URL: https://build.opensuse.org/package/show/devel:languages:lua/StyLua?expand=0&rev=13
2023-02-17 10:34:35 +00:00
2622e8eb21 Accepting request 1065633 from devel:languages:lua
OBS-URL: https://build.opensuse.org/request/show/1065633
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/StyLua?expand=0&rev=5
2023-02-14 15:47:06 +00:00
Soc Virnyl Estela
76e0f5c3a0 Accepting request 1065632 from home:firstyear:branches:devel:languages:lua
Automatic update of vendored dependencies

OBS-URL: https://build.opensuse.org/request/show/1065632
OBS-URL: https://build.opensuse.org/package/show/devel:languages:lua/StyLua?expand=0&rev=11
2023-02-14 02:10:50 +00:00
ccdb4c5c75 Accepting request 1063084 from devel:languages:lua
Automatic submission by obs-autosubmit

OBS-URL: https://build.opensuse.org/request/show/1063084
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/StyLua?expand=0&rev=4
2023-02-04 13:15:38 +00:00
Soc Virnyl Estela
71bbb8a2aa - Update to version 0.16.0:
* Fixed an anonymous function assignment local x = function() being unnecessarily indented if the function body contains a comment (#627)
  * Fixed malformed formatting when there is a newline between a return token and the expressions (#605)
  * Fixed malformed formatting of multi-assignment or multi-returns where there is a comment within the expressions list (#637)
  * Update internal parser:
    - (lua52) Support Lua 5.2 fractional hexidecimal / hexidecimal with exponents (#621)
    - (lua52) Support LuaJIT number suffixes LL/ULL/i (#621)
    - (lua52) Support \z escape sequences in strings (#613)
    - (luau) Support Luau string interpolation (#607)
  * Several optimisations applied to formatting functions to reduce time taken. Files which previously did not terminate (6MB+) now finish in reasonable time. (#591)
  * Assignments of the form local name = function will no longer hang at the equals token, and instead force parameters multiline, to reduce unnecessary indentation. (#595)
  * Unnecessary parentheses around Luau types will now be removed (#611)
  * Collapse a body containing only a goto statement when collapse_simple_statement is set (#618)

OBS-URL: https://build.opensuse.org/package/show/devel:languages:lua/StyLua?expand=0&rev=9
2023-01-28 00:58:39 +00:00
8b4f99d489 Accepting request 1045044 from devel:languages:lua
Automatic submission by obs-autosubmit

OBS-URL: https://build.opensuse.org/request/show/1045044
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/StyLua?expand=0&rev=3
2022-12-24 13:52:00 +00:00
Soc Virnyl Estela
bb7e58fdc1 - Disable --all-features in test since cargo-insta is
not installed or available in openSUSE.

OBS-URL: https://build.opensuse.org/package/show/devel:languages:lua/StyLua?expand=0&rev=7
2022-12-16 16:01:23 +00:00
Soc Virnyl Estela
552bee1552 - Update to version 0.15.3:
* Fixed necessary parentheses removed in (-X) ^ Y causing change in semantics
  * Take into account function token size when formatting an anonymous function function() end (particularly relevant when collapsing simple statements)
  * Support hanging inside of Luau type arrays { T } to fix formatting issues when comments are present

OBS-URL: https://build.opensuse.org/package/show/devel:languages:lua/StyLua?expand=0&rev=6
2022-12-16 14:22:35 +00:00
ed25cfbbdc Accepting request 1039331 from devel:languages:lua
Automatic submission by obs-autosubmit

OBS-URL: https://build.opensuse.org/request/show/1039331
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/StyLua?expand=0&rev=2
2022-12-01 16:21:38 +00:00
Soc Virnyl Estela
119ada4d16 - Remove strip option for debuginfo creation.
OBS-URL: https://build.opensuse.org/package/show/devel:languages:lua/StyLua?expand=0&rev=4
2022-11-24 13:56:49 +00:00
1ac7183cb7 Accepting request 1037038 from devel:languages:lua
I want to maintain StyLua in openSUSE:Factory

OBS-URL: https://build.opensuse.org/request/show/1037038
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/StyLua?expand=0&rev=1
2022-11-21 14:30:04 +00:00
Soc Virnyl Estela
0a9b92c38a - Rename source tarball to StyLua-0.15.2.tar.gz.
- Update _service file.

OBS-URL: https://build.opensuse.org/package/show/devel:languages:lua/StyLua?expand=0&rev=2
2022-11-21 06:41:00 +00:00
edb6aa0801 Accepting request 1037000 from home:uncomfyhalomacro
I want to maintain StyLua in devel:languages:lua

OBS-URL: https://build.opensuse.org/request/show/1037000
OBS-URL: https://build.opensuse.org/package/show/devel:languages:lua/StyLua?expand=0&rev=1
2022-11-21 05:35:35 +00:00