Upgrade to Swift 5.3
This commit is contained in:
parent
47a5ea410f
commit
89bfdf0049
|
@ -81,7 +81,6 @@ whitelist_rules:
|
||||||
- operator_whitespace
|
- operator_whitespace
|
||||||
- orphaned_doc_comment
|
- orphaned_doc_comment
|
||||||
- overridden_super_call
|
- overridden_super_call
|
||||||
- pattern_matching_keywords
|
|
||||||
- prefer_self_type_over_type_of_self
|
- prefer_self_type_over_type_of_self
|
||||||
- private_action
|
- private_action
|
||||||
- private_outlet
|
- private_outlet
|
||||||
|
@ -109,7 +108,6 @@ whitelist_rules:
|
||||||
- switch_case_alignment
|
- switch_case_alignment
|
||||||
- switch_case_on_newline
|
- switch_case_on_newline
|
||||||
- syntactic_sugar
|
- syntactic_sugar
|
||||||
- todo
|
|
||||||
- toggle_bool
|
- toggle_bool
|
||||||
- trailing_closure
|
- trailing_closure
|
||||||
- trailing_comma
|
- trailing_comma
|
||||||
|
@ -121,7 +119,6 @@ whitelist_rules:
|
||||||
- unneeded_parentheses_in_closure_argument
|
- unneeded_parentheses_in_closure_argument
|
||||||
- unowned_variable_capture
|
- unowned_variable_capture
|
||||||
- untyped_error_in_catch
|
- untyped_error_in_catch
|
||||||
- unused_capture_list
|
|
||||||
- unused_closure_parameter
|
- unused_closure_parameter
|
||||||
- unused_control_flow_label
|
- unused_control_flow_label
|
||||||
- unused_enumerated
|
- unused_enumerated
|
||||||
|
|
|
@ -8,6 +8,6 @@ Pod::Spec.new do |s|
|
||||||
s.authors = { 'Sindre Sorhus' => 'sindresorhus@gmail.com' }
|
s.authors = { 'Sindre Sorhus' => 'sindresorhus@gmail.com' }
|
||||||
s.source = { :git => 'https://github.com/sindresorhus/DockProgress.git', :tag => "v#{s.version}" }
|
s.source = { :git => 'https://github.com/sindresorhus/DockProgress.git', :tag => "v#{s.version}" }
|
||||||
s.source_files = 'Sources/**/*.swift'
|
s.source_files = 'Sources/**/*.swift'
|
||||||
s.swift_version = '5.2'
|
s.swift_version = '5.3'
|
||||||
s.platform = :macos, '10.12'
|
s.platform = :macos, '10.12'
|
||||||
end
|
end
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
archiveVersion = 1;
|
archiveVersion = 1;
|
||||||
classes = {
|
classes = {
|
||||||
};
|
};
|
||||||
objectVersion = 52;
|
objectVersion = 54;
|
||||||
objects = {
|
objects = {
|
||||||
|
|
||||||
/* Begin PBXBuildFile section */
|
/* Begin PBXBuildFile section */
|
||||||
|
@ -181,7 +181,7 @@
|
||||||
isa = PBXProject;
|
isa = PBXProject;
|
||||||
attributes = {
|
attributes = {
|
||||||
LastSwiftUpdateCheck = 0940;
|
LastSwiftUpdateCheck = 0940;
|
||||||
LastUpgradeCheck = 1160;
|
LastUpgradeCheck = 1200;
|
||||||
TargetAttributes = {
|
TargetAttributes = {
|
||||||
"DockProgress::DockProgress" = {
|
"DockProgress::DockProgress" = {
|
||||||
LastSwiftMigration = 1020;
|
LastSwiftMigration = 1020;
|
||||||
|
@ -193,7 +193,7 @@
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
buildConfigurationList = OBJ_2 /* Build configuration list for PBXProject "DockProgress" */;
|
buildConfigurationList = OBJ_2 /* Build configuration list for PBXProject "DockProgress" */;
|
||||||
compatibilityVersion = "Xcode 11.0";
|
compatibilityVersion = "Xcode 12.0";
|
||||||
developmentRegion = en;
|
developmentRegion = en;
|
||||||
hasScannedForEncodings = 0;
|
hasScannedForEncodings = 0;
|
||||||
knownRegions = (
|
knownRegions = (
|
||||||
|
@ -463,6 +463,7 @@
|
||||||
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
|
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
|
||||||
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
|
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
|
||||||
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
|
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
|
||||||
|
CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES;
|
||||||
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
|
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
|
||||||
CLANG_WARN_STRICT_PROTOTYPES = YES;
|
CLANG_WARN_STRICT_PROTOTYPES = YES;
|
||||||
CLANG_WARN_SUSPICIOUS_MOVE = YES;
|
CLANG_WARN_SUSPICIOUS_MOVE = YES;
|
||||||
|
@ -512,6 +513,7 @@
|
||||||
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
|
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
|
||||||
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
|
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
|
||||||
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
|
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
|
||||||
|
CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES;
|
||||||
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
|
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
|
||||||
CLANG_WARN_STRICT_PROTOTYPES = YES;
|
CLANG_WARN_STRICT_PROTOTYPES = YES;
|
||||||
CLANG_WARN_SUSPICIOUS_MOVE = YES;
|
CLANG_WARN_SUSPICIOUS_MOVE = YES;
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
<?xml version="1.0" encoding="UTF-8"?>
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
<Scheme
|
<Scheme
|
||||||
LastUpgradeVersion = "1160"
|
LastUpgradeVersion = "1200"
|
||||||
version = "1.3">
|
version = "1.3">
|
||||||
<BuildAction
|
<BuildAction
|
||||||
parallelizeBuildables = "YES"
|
parallelizeBuildables = "YES"
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
<?xml version="1.0" encoding="UTF-8"?>
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
<Scheme
|
<Scheme
|
||||||
LastUpgradeVersion = "1160"
|
LastUpgradeVersion = "1200"
|
||||||
version = "1.3">
|
version = "1.3">
|
||||||
<BuildAction
|
<BuildAction
|
||||||
parallelizeBuildables = "YES"
|
parallelizeBuildables = "YES"
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
import Cocoa
|
import Cocoa
|
||||||
import DockProgress
|
import DockProgress
|
||||||
|
|
||||||
@NSApplicationMain
|
@main
|
||||||
final class AppDelegate: NSObject, NSApplicationDelegate {
|
final class AppDelegate: NSObject, NSApplicationDelegate {
|
||||||
func borrowIconFromApp(_ app: String) {
|
func borrowIconFromApp(_ app: String) {
|
||||||
let icon = NSWorkspace.shared.icon(forFile: NSWorkspace.shared.fullPath(forApplication: app)!)
|
let icon = NSWorkspace.shared.icon(forFile: NSWorkspace.shared.fullPath(forApplication: app)!)
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// swift-tools-version:5.2
|
// swift-tools-version:5.3
|
||||||
import PackageDescription
|
import PackageDescription
|
||||||
|
|
||||||
let package = Package(
|
let package = Package(
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
import Cocoa
|
import Cocoa
|
||||||
|
|
||||||
public final class DockProgress {
|
public enum DockProgress {
|
||||||
private static var previousProgress: Double = 0
|
private static var previousProgress: Double = 0
|
||||||
private static var progressObserver: NSKeyValueObservation?
|
private static var progressObserver: NSKeyValueObservation?
|
||||||
private static var finishedObserver: NSKeyValueObservation?
|
private static var finishedObserver: NSKeyValueObservation?
|
||||||
|
|
Loading…
Reference in New Issue