From ea3451ae941336b133d46be6b0dc99590ba3fba0 Mon Sep 17 00:00:00 2001 From: Eric Marchand Date: Tue, 25 Sep 2018 14:09:50 +0200 Subject: [PATCH 1/6] Update .travis.yml --- .travis.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index a247a79..9d97aee 100644 --- a/.travis.yml +++ b/.travis.yml @@ -8,7 +8,7 @@ env: - IOS_FRAMEWORK_SCHEME="FileKit-iOS" - MACOS_FRAMEWORK_SCHEME="FileKit-OSX" - IOS_SDK=iphonesimulator12.0 - - MACOS_SDK=macosx10.13 + - MACOS_SDK=macosx10.14 matrix: - DESTINATION="OS=12.0,name=iPhone 8" SCHEME="$IOS_FRAMEWORK_SCHEME" SDK="$IOS_SDK" RUN_TESTS="NO" - DESTINATION="arch=x86_64" SCHEME="$MACOS_FRAMEWORK_SCHEME" SDK="$MACOS_SDK" RUN_TESTS="YES" From 5b47cfcba2fa30c620e81b92868c1c181a132aa3 Mon Sep 17 00:00:00 2001 From: Eric Marchand Date: Mon, 8 Apr 2019 15:29:02 +0200 Subject: [PATCH 2/6] Fix Xcode 10.2 warnings --- FileKit.xcodeproj/project.pbxproj | 5 +++-- .../xcschemes/FileKit-OSX.xcscheme | 2 +- .../xcschemes/FileKit-iOS.xcscheme | 2 +- .../xcschemes/FileKit-tvOS.xcscheme | 2 +- .../xcschemes/FileKit-watchOS.xcscheme | 2 +- .../xcschemes/FileKitTests.xcscheme | 2 +- Sources/DispatchWatcher.swift | 18 +++++++++--------- Sources/Path.swift | 6 +++--- 8 files changed, 20 insertions(+), 19 deletions(-) diff --git a/FileKit.xcodeproj/project.pbxproj b/FileKit.xcodeproj/project.pbxproj index 46bffa0..dec18aa 100644 --- a/FileKit.xcodeproj/project.pbxproj +++ b/FileKit.xcodeproj/project.pbxproj @@ -495,7 +495,7 @@ isa = PBXProject; attributes = { LastSwiftUpdateCheck = 0700; - LastUpgradeCheck = 0930; + LastUpgradeCheck = 1020; ORGANIZATIONNAME = "Nikolai Vazquez"; TargetAttributes = { 5204B84A1B96B83800AA473F = { @@ -520,10 +520,11 @@ }; buildConfigurationList = 5204B7B01B968B8600AA473F /* Build configuration list for PBXProject "FileKit" */; compatibilityVersion = "Xcode 3.2"; - developmentRegion = English; + developmentRegion = en; hasScannedForEncodings = 0; knownRegions = ( en, + Base, ); mainGroup = 5204B7AC1B968B8600AA473F; productRefGroup = 5204B7B71B968B8600AA473F /* Products */; diff --git a/FileKit.xcodeproj/xcshareddata/xcschemes/FileKit-OSX.xcscheme b/FileKit.xcodeproj/xcshareddata/xcschemes/FileKit-OSX.xcscheme index 44b344c..3e7bb33 100644 --- a/FileKit.xcodeproj/xcshareddata/xcschemes/FileKit-OSX.xcscheme +++ b/FileKit.xcodeproj/xcshareddata/xcschemes/FileKit-OSX.xcscheme @@ -1,6 +1,6 @@ Date: Mon, 8 Apr 2019 16:03:46 +0200 Subject: [PATCH 3/6] Update travis file for xcode 10.2 --- .travis.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.travis.yml b/.travis.yml index 9d97aee..ce42220 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,5 +1,5 @@ language: objective-c -osx_image: xcode10 +osx_image: xcode10.2 env: global: - LC_CTYPE=en_US.UTF-8 @@ -7,10 +7,10 @@ env: - PROJECT=FileKit.xcodeproj - IOS_FRAMEWORK_SCHEME="FileKit-iOS" - MACOS_FRAMEWORK_SCHEME="FileKit-OSX" - - IOS_SDK=iphonesimulator12.0 + - IOS_SDK=iphonesimulator12.2 - MACOS_SDK=macosx10.14 matrix: - - DESTINATION="OS=12.0,name=iPhone 8" SCHEME="$IOS_FRAMEWORK_SCHEME" SDK="$IOS_SDK" RUN_TESTS="NO" + - DESTINATION="OS=12.2,name=iPhone 8" SCHEME="$IOS_FRAMEWORK_SCHEME" SDK="$IOS_SDK" RUN_TESTS="NO" - DESTINATION="arch=x86_64" SCHEME="$MACOS_FRAMEWORK_SCHEME" SDK="$MACOS_SDK" RUN_TESTS="YES" before_install: - gem install xcpretty --no-rdoc --no-ri --no-document --quiet From 48b5ddb287f131a5c628badc819b880453f94449 Mon Sep 17 00:00:00 2001 From: Davide Mazzoni Date: Wed, 20 Mar 2019 12:14:46 +0100 Subject: [PATCH 4/6] Update Package.swift to API v4.2 --- Package.swift | 21 +++++++++++++++++++-- 1 file changed, 19 insertions(+), 2 deletions(-) diff --git a/Package.swift b/Package.swift index c11c1b7..845b0bf 100644 --- a/Package.swift +++ b/Package.swift @@ -1,3 +1,4 @@ +// swift-tools-version:4.2 // // Package.swift // FileKit @@ -29,7 +30,23 @@ import PackageDescription let package = Package( name: "FileKit", - exclude: [ - "Tests" + products: [ + // Products define the executables and libraries produced by a package, and make them visible to other packages. + .library( + name: "FileKit", + targets: ["FileKit"]), + ], + dependencies: [], + targets: [ + // Targets are the basic building blocks of a package. A target can define a module or a test suite. + // Targets can depend on other targets in this package, and on products in packages which this package depends on. + .target( + name: "FileKit", + dependencies: [], + path: "Sources"), + .testTarget( + name: "FileKitTests", + dependencies: ["FileKit"], + path: "Tests") ] ) From 886dc4808fb6419fd62f49c2a49b4a05a02f1c01 Mon Sep 17 00:00:00 2001 From: phimage Date: Sun, 1 Sep 2019 21:15:52 +0200 Subject: [PATCH 5/6] Fix swiftlint useless warning. Fix test --- Sources/DataType.swift | 4 ++-- Tests/FileKitTests.swift | 6 +++++- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/Sources/DataType.swift b/Sources/DataType.swift index ea06023..a1a4758 100644 --- a/Sources/DataType.swift +++ b/Sources/DataType.swift @@ -47,7 +47,7 @@ extension Readable { /// /// - Parameter path: The path being read from. /// - public init(contentsOfPath path: Path) throws { // swiftlint:disable:this valid_docs + public init(contentsOfPath path: Path) throws { self = try Self.read(from: path) } @@ -77,7 +77,7 @@ extension Writable { /// /// - Parameter path: The path being written to. /// - public func write(to path: Path) throws { // swiftlint:disable:this valid_docs + public func write(to path: Path) throws { try write(to: path, atomically: true) } diff --git a/Tests/FileKitTests.swift b/Tests/FileKitTests.swift index 49d2dab..bd3ac14 100644 --- a/Tests/FileKitTests.swift +++ b/Tests/FileKitTests.swift @@ -199,7 +199,11 @@ class FileKitTests: XCTestCase { let directories = children.filter { $0.isDirectory } - guard let directory = directories.first, let childOfChild = directory.children().first else { + if let directory = directories.first, directory.children().isEmpty { + try? (directory + "childOfChild").createDirectory() + } + + guard let directory = directories.first, let childOfChild = directory.children().first else { XCTFail("No child of child into \(p)") return } From 7133459387efb97d2e49d35ffa69274d30d86c46 Mon Sep 17 00:00:00 2001 From: phimage Date: Sun, 1 Sep 2019 21:17:22 +0200 Subject: [PATCH 6/6] Update podspec to 5.3 --- FileKit.podspec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/FileKit.podspec b/FileKit.podspec index a4412fc..6eff8c2 100644 --- a/FileKit.podspec +++ b/FileKit.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = "FileKit" - s.version = "5.2.0" + s.version = "5.3.0" s.summary = "Simple and expressive file management in Swift." s.homepage = "https://github.com/nvzqz/FileKit" s.license = { :type => "MIT", :file => "LICENSE.md" }