diff --git a/CHANGELOG.md b/CHANGELOG.md index 8492d7de..626b5955 100755 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,15 +1,31 @@ # Change Log +## [0.52.0](https://github.com/nicklockwood/SwiftFormat/releases/tag/0.52.0) (2023-08-13) + +- Added `redundantInternal` rule to remove redundant `internal` access modifiers +- Added `sortTypealiases` rule to sort `typealias` types alphabetically +- Added `headerFileName` rule to ensure filename in header comment matches actual file +- Added `redundantStaticSelf` rule to remove redundant `self` inside static functions +- Added `blankLinesBetweenChainedFunctions` rule to remove blank lines inside function chains +- Added `applicationMain` rule to remove obsolete `@UIApplicationMain` and `@NSApplicationMain` attributes +- Renamed `sortedSwitchCases` rule to `sortSwitchCases` for consistency +- Renamed `sortedImports` rule to `sortImports` for consistency +- Redundant `return` is now correctly removed in switch cases with associated values +- Fixed failure to terminate when removing returns from long switch statement +- Fixed spurious "unexpected static" error in `redundantSelf` rule +- Deliberate blank line before `else` statement is now preserved +- Rule options are now case-insensitive + ## [0.51.15](https://github.com/nicklockwood/SwiftFormat/releases/tag/0.51.15) (2023-08-06) -- This release actually includes the fixes listed for 0.51.14 (these were accidentally reverted in a merge error). - -## [0.51.14](https://github.com/nicklockwood/SwiftFormat/releases/tag/0.51.14) (2023-08-05) - - Fixed regression in `unusedArguments` rule that caused used parameters to be marked unused - Fixed some additional cases where regex literal was mistaken for `/` operator - Vertical tab and form feed characters in source file no longer cause spurious errors +## [0.51.14](https://github.com/nicklockwood/SwiftFormat/releases/tag/0.51.14) (2023-08-05) + +- Withdrawn + ## [0.51.13](https://github.com/nicklockwood/SwiftFormat/releases/tag/0.51.13) (2023-07-18) - Fixed bug where importing a type caused the `redundantSelf` rule to be silently disabled diff --git a/CommandLineTool/swiftformat b/CommandLineTool/swiftformat index bc4bb994..efc45f7d 100755 Binary files a/CommandLineTool/swiftformat and b/CommandLineTool/swiftformat differ diff --git a/EditorExtension/Application/Source/BinarySelectionTableCellView.swift b/EditorExtension/Application/Source/BinarySelectionTableCellView.swift index 1535f1a2..43b8bfaf 100644 --- a/EditorExtension/Application/Source/BinarySelectionTableCellView.swift +++ b/EditorExtension/Application/Source/BinarySelectionTableCellView.swift @@ -1,5 +1,5 @@ // -// RuleSelectionTableCellView.swift +// BinarySelectionTableCellView.swift // SwiftFormat for Xcode // // Created by Vincent Bernier on 28/01/18. diff --git a/Sources/Formatter.swift b/Sources/Formatter.swift index 948fcf04..a0d98d81 100644 --- a/Sources/Formatter.swift +++ b/Sources/Formatter.swift @@ -2,7 +2,7 @@ // Formatter.swift // SwiftFormat // -// Version 0.51.15 +// Version 0.52.0 // // Created by Nick Lockwood on 12/08/2016. // Copyright 2016 Nick Lockwood diff --git a/Sources/SwiftFormat.swift b/Sources/SwiftFormat.swift index 6747a7e0..678252c2 100644 --- a/Sources/SwiftFormat.swift +++ b/Sources/SwiftFormat.swift @@ -32,7 +32,7 @@ import Foundation /// The current SwiftFormat version -let swiftFormatVersion = "0.51.15" +let swiftFormatVersion = "0.52.0" public let version = swiftFormatVersion /// The standard SwiftFormat config file name diff --git a/Sources/Tokenizer.swift b/Sources/Tokenizer.swift index 7d9f7a04..4fddd3b1 100644 --- a/Sources/Tokenizer.swift +++ b/Sources/Tokenizer.swift @@ -2,7 +2,7 @@ // Tokenizer.swift // SwiftFormat // -// Version 0.51.15 +// Version 0.52.0 // // Created by Nick Lockwood on 11/08/2016. // Copyright 2016 Nick Lockwood diff --git a/SwiftFormat.podspec.json b/SwiftFormat.podspec.json index 4a39d39e..22036cac 100644 --- a/SwiftFormat.podspec.json +++ b/SwiftFormat.podspec.json @@ -1,6 +1,6 @@ { "name": "SwiftFormat", - "version": "0.51.15", + "version": "0.52.0", "license": { "type": "MIT", "file": "LICENSE.md" @@ -10,7 +10,7 @@ "authors": "Nick Lockwood", "source": { "git": "https://github.com/nicklockwood/SwiftFormat.git", - "tag": "0.51.15" + "tag": "0.52.0" }, "default_subspecs": "Core", "subspecs": [ diff --git a/SwiftFormat.xcodeproj/project.pbxproj b/SwiftFormat.xcodeproj/project.pbxproj index a2aeec4b..e4a4336e 100644 --- a/SwiftFormat.xcodeproj/project.pbxproj +++ b/SwiftFormat.xcodeproj/project.pbxproj @@ -1111,7 +1111,7 @@ "@loader_path/Frameworks", ); MACOSX_DEPLOYMENT_TARGET = 10.14; - MARKETING_VERSION = 0.51.15; + MARKETING_VERSION = 0.52.0; MODULE_VERIFIER_SUPPORTED_LANGUAGES = "objective-c objective-c++"; MODULE_VERIFIER_SUPPORTED_LANGUAGE_STANDARDS = "gnu99 gnu++11"; PRODUCT_BUNDLE_IDENTIFIER = com.charcoaldesign.SwiftFormat; @@ -1144,7 +1144,7 @@ "@loader_path/Frameworks", ); MACOSX_DEPLOYMENT_TARGET = 10.14; - MARKETING_VERSION = 0.51.15; + MARKETING_VERSION = 0.52.0; MODULE_VERIFIER_SUPPORTED_LANGUAGES = "objective-c objective-c++"; MODULE_VERIFIER_SUPPORTED_LANGUAGE_STANDARDS = "gnu99 gnu++11"; PRODUCT_BUNDLE_IDENTIFIER = com.charcoaldesign.SwiftFormat; @@ -1251,7 +1251,7 @@ "@executable_path/../Frameworks", ); MACOSX_DEPLOYMENT_TARGET = 10.14; - MARKETING_VERSION = 0.51.15; + MARKETING_VERSION = 0.52.0; PRODUCT_BUNDLE_IDENTIFIER = "com.charcoaldesign.SwiftFormat-for-Xcode"; PRODUCT_NAME = "SwiftFormat for Xcode"; PROVISIONING_PROFILE_SPECIFIER = ""; @@ -1282,7 +1282,7 @@ "@executable_path/../Frameworks", ); MACOSX_DEPLOYMENT_TARGET = 10.14; - MARKETING_VERSION = 0.51.15; + MARKETING_VERSION = 0.52.0; PRODUCT_BUNDLE_IDENTIFIER = "com.charcoaldesign.SwiftFormat-for-Xcode"; PRODUCT_NAME = "SwiftFormat for Xcode"; PROVISIONING_PROFILE_SPECIFIER = ""; @@ -1310,7 +1310,7 @@ "@executable_path/../../../../Frameworks", ); MACOSX_DEPLOYMENT_TARGET = 10.14; - MARKETING_VERSION = 0.51.15; + MARKETING_VERSION = 0.52.0; PRODUCT_BUNDLE_IDENTIFIER = "com.charcoaldesign.SwiftFormat-for-Xcode.SourceEditorExtension"; PRODUCT_NAME = SwiftFormat; PROVISIONING_PROFILE_SPECIFIER = ""; @@ -1340,7 +1340,7 @@ "@executable_path/../../../../Frameworks", ); MACOSX_DEPLOYMENT_TARGET = 10.14; - MARKETING_VERSION = 0.51.15; + MARKETING_VERSION = 0.52.0; PRODUCT_BUNDLE_IDENTIFIER = "com.charcoaldesign.SwiftFormat-for-Xcode.SourceEditorExtension"; PRODUCT_NAME = SwiftFormat; PROVISIONING_PROFILE_SPECIFIER = ""; diff --git a/SwiftFormat.xcodeproj/project.xcworkspace/contents.xcworkspacedata b/SwiftFormat.xcodeproj/project.xcworkspace/contents.xcworkspacedata index aabfbf0f..919434a6 100644 --- a/SwiftFormat.xcodeproj/project.xcworkspace/contents.xcworkspacedata +++ b/SwiftFormat.xcodeproj/project.xcworkspace/contents.xcworkspacedata @@ -2,6 +2,6 @@ + location = "self:">