Skip to content

Commit

Permalink
Merge pull request #21 from marcprux/main
Browse files Browse the repository at this point in the history
Cross-platform CI and conditional import of CloudKit
  • Loading branch information
drewmccormack authored Jan 10, 2025
2 parents 243c078 + 822df86 commit a011d34
Show file tree
Hide file tree
Showing 4 changed files with 46 additions and 2 deletions.
39 changes: 39 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
name: Forked ci
on:
push:
workflow_dispatch:
pull_request:
jobs:
macos-ios:
runs-on: macos-15
steps:
- uses: actions/checkout@v4
- name: "Test Swift Package on macOS"
run: swift test
- name: "Build Swift Package on iOS"
run: xcodebuild build -skipMacroValidation -skipPackagePluginValidation -sdk "iphonesimulator" -destination "platform=iOS Simulator,name=iPhone 16" -scheme "Forked-Package"
#run: xcodebuild test -skipMacroValidation -skipPackagePluginValidation -sdk "iphonesimulator" -destination "platform=iOS Simulator,name=iPhone 16" -scheme "Forked-Package"
linux-android:
runs-on: ubuntu-24.04
steps:
- uses: actions/checkout@v4
- name: "Test Swift Package on Linux"
run: swift test
- name: "Build Swift Package on Android"
uses: skiptools/swift-android-action@v2
with:
# Android SDK does not yet support Testing framework
build-tests: false
windows:
runs-on: windows-latest
# Error: error: invalid path 'docs/Forked/data/documentation/forked/atomicrepository/content(of:at:).json'
if: false
steps:
- uses: compnerd/gha-setup-swift@main
with:
branch: swift-6.0.3-release
tag: 6.0.3-RELEASE
- uses: actions/checkout@v4
- name: "Test Swift Package on Windows"
run: swift test

Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#if canImport(CloudKit)
import CloudKit
import os.log

Expand Down Expand Up @@ -71,3 +72,5 @@ extension CloudKitExchange: CKSyncEngineDelegate {
}

}
#endif

Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#if canImport(CloudKit)
import CloudKit
import Forked
import os.log
Expand Down Expand Up @@ -177,5 +178,4 @@ extension CloudKitExchange {


}


#endif
2 changes: 2 additions & 0 deletions Sources/ForkedCloudKit/CloudKitExchange.swift
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#if canImport(CloudKit)
import CloudKit
import SwiftUI
import AsyncAlgorithms
Expand Down Expand Up @@ -248,4 +249,5 @@ internal extension CloudKitExchange {
}

}
#endif

0 comments on commit a011d34

Please sign in to comment.