diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index b567416..aa25daa 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -8,12 +8,12 @@ on: jobs: build: - runs-on: macos-13 + runs-on: macos-14 steps: - name: Checkout repository uses: actions/checkout@v3 - name: Select Xcode version - run: sudo xcode-select -s '/Applications/Xcode_15.0.app/Contents/Developer' + run: sudo xcode-select -s '/Applications/Xcode_16.1.0.app/Contents/Developer' - name: Run fastlane env: EMERGE_API_TOKEN: ${{ secrets.EMERGE_API_TOKEN }} diff --git a/.gitignore b/.gitignore index 5509140..081a9f4 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,3 @@ *.DS_Store +.build +.swiftpm \ No newline at end of file diff --git a/Example/Pow Example.xcodeproj/project.pbxproj b/Example/Pow Example.xcodeproj/project.pbxproj index 8feb6ef..8f89473 100644 --- a/Example/Pow Example.xcodeproj/project.pbxproj +++ b/Example/Pow Example.xcodeproj/project.pbxproj @@ -721,7 +721,7 @@ PRODUCT_BUNDLE_IDENTIFIER = "io.movingparts.Pow-Example.Debug"; PRODUCT_NAME = "$(TARGET_NAME)"; SWIFT_EMIT_LOC_STRINGS = YES; - SWIFT_VERSION = 5.0; + SWIFT_VERSION = 6.0; TARGETED_DEVICE_FAMILY = "1,2"; }; name = Debug; @@ -753,7 +753,7 @@ PRODUCT_BUNDLE_IDENTIFIER = "io.movingparts.Pow-Example"; PRODUCT_NAME = "$(TARGET_NAME)"; SWIFT_EMIT_LOC_STRINGS = YES; - SWIFT_VERSION = 5.0; + SWIFT_VERSION = 6.0; TARGETED_DEVICE_FAMILY = "1,2"; }; name = Release; @@ -787,7 +787,7 @@ repositoryURL = "https://github.com/EmergeTools/SnapshotPreviews-iOS"; requirement = { kind = exactVersion; - version = 0.7.6; + version = 0.10.21; }; }; /* End XCRemoteSwiftPackageReference section */ diff --git a/Example/Pow Example/ExampleList.swift b/Example/Pow Example/ExampleList.swift index f206829..bb47904 100644 --- a/Example/Pow Example/ExampleList.swift +++ b/Example/Pow Example/ExampleList.swift @@ -109,21 +109,21 @@ struct ExampleList: View { } } -struct PresentInfoAction { - var action: (any Example.Type) -> () +struct PresentInfoAction: Sendable { + var action: @MainActor (any Example.Type) -> () - init(action: @escaping (any Example.Type) -> Void) { + init(action: @escaping @MainActor (any Example.Type) -> Void) { self.action = action } - func callAsFunction(_ type: T.Type) { + @MainActor func callAsFunction(_ type: T.Type) { action(type) } } extension EnvironmentValues { - struct PresentInfoActionKey: EnvironmentKey { - static var defaultValue: PresentInfoAction? = nil + struct PresentInfoActionKey: EnvironmentKey { + static let defaultValue: PresentInfoAction? = nil } var presentInfoAction: PresentInfoAction? { diff --git a/Package.swift b/Package.swift index 706cea1..9a61280 100644 --- a/Package.swift +++ b/Package.swift @@ -22,7 +22,7 @@ let package = Package( dependencies: [ // Dependencies declare other packages that this package depends on. // .package(url: /* package url */, from: "1.0.0"), - .package(url: "https://github.com/EmergeTools/SnapshotPreviews-iOS", exact: "0.7.6") + .package(url: "https://github.com/EmergeTools/SnapshotPreviews-iOS", exact: "0.10.21") ], targets: [ // Targets are the basic building blocks of a package. A target can define a module or a test suite. @@ -35,5 +35,6 @@ let package = Package( .testTarget( name: "PowTests", dependencies: ["Pow"]), - ] + ], + swiftLanguageVersions: [.v5] )