Skip to content

Releases: nicklockwood/SwiftFormat

0.49.13

15 Jul 22:02
Compare
Choose a tag to compare
  • Fixed for...in mistaken for closure in in indent rule
  • Fixed incorrect spacing around @MainActor

0.49.12

13 Jul 21:19
Compare
Choose a tag to compare
  • Fix bug with parsing ternary chains containing chevron
  • Add another fix for / operator
  • Fix indent after wrapped closure in
  • Improve rule search in SwiftFormat for Xcode app
  • Fix enum popups in SwiftFormat for Xcode options
  • Added prebuilt SPM binary target

0.49.11

22 Jun 22:00
Compare
Choose a tag to compare
  • Fixed parsing of prefix / operator (as used in CasePath library)
  • Fixed bug with indenting of trailing closures after a conditional statement
  • Fixed bug with wrapMultilineStatementBraces rule
  • Added Swift 5.6 and 5.7 to supported versions

0.49.10

18 Jun 21:45
Compare
Choose a tag to compare
  • Added preliminary support for Swift 5.7 regular expression literals
  • Fixed conflict between wrapMultilineStatementBraces and indent rules
  • Fixed bug where arguments referenced using $ prefix were incorrectly marked as unused
  • Fixed enumNamespaces bug where class modifiers were mistakenly converted to enum
  • Fixed bug where preferKeyPath mangled functions using multiple trailing closure syntax
  • Unterminated string literals are now treated as an error

0.49.9

17 May 05:39
Compare
Choose a tag to compare
  • Fixed bug where trailing comma was incorrectly added inside collection types
  • Fixed some cases where redundantVoidReturnType failed to remove Void
  • Fixed unusedArguments regression introduced in 0.49.8

0.49.8

03 May 00:04
Compare
Choose a tag to compare
  • Fixed redundantInit rule removing required init when instantiating type variables
  • Fixed unusedArguments incorrectly marking shadowed parameters as used or unused in some cases

0.49.7

03 Apr 23:19
Compare
Choose a tag to compare
  • Redundant self is now correctly removed in if let assignments
  • Fixed infinite recursion bug that would cause formatting to time out for some inputs
  • Lint failure now returns an error code when using stdin, matching behavior for file inputs
  • Fixed bug where parens were incorrectly removed around optional ranges
  • Updated unusedParens rule for new shorthand if let syntax in Swift 5.7
  • Updated indenting of function chains to match latest Xcode behavior
  • Fixed build error on macOS 10.11 and earlier

0.49.6

15 Mar 22:59
Compare
Choose a tag to compare
  • Fixed bug where redundantParens rule removed required parens in any type expressions
  • Fixed whitespace behavior around some/any keywords
  • Fixed crash when // swiftformat:sort was applied to an enum with only one case
  • SwiftFormat can now be built on Windows

0.49.5

07 Mar 00:06
Compare
Choose a tag to compare
  • Fixed bug where redundantClosure incorrectly inlined throwing closures
  • Fixed bug where in --exclude path matching failed when using --stdinpath
  • Fixed a bug with typeSugar rule when overriding stdlib types locally in your code
  • Multiline statement braces are now unwrapped if wrapMultilineStatementBraces disabled
  • Added // swiftformat:sort directive to sort declarations by name
  • You can now use --disable all or --enable all as shorthand for all rules
  • The rules in the Rules.md file are now grouped by their default/enabled status

0.49.4

07 Feb 22:49
Compare
Choose a tag to compare
  • Fixed creation date being modified on formatted files
  • Fixed case where a closure inside an if condition was mistaken for the body
  • Fixed blockComments rule removing leading *s used as bullet points
  • Fixed bug when parsing a raw string containing three consecutive unescaped quotes
  • Fixed spurious warning about unused --wrapparameters option
  • Fixed edge case when using --allman indenting