Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 21 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -60,3 +60,24 @@ jobs:
token: ${{ secrets.CODECOV_TOKEN }}
files: coverage.lcov
fail_ci_if_error: false

linux:
name: Linux build
# The modules that use no Apple framework must build on Linux, where SoundcheckPlayer tests its pure targets (#13).
# Not the whole package: CoreAudioIO, MixerLink, Appearance and Meters need AudioToolbox, Network and SwiftUI, and
# BroadcastWaveTests needs AVFoundation. `swift test` builds every test target, so the tests run on macOS only.
runs-on: ubuntu-latest
container: swift:6.2
timeout-minutes: 15
steps:
- uses: actions/checkout@v4

- name: Show toolchain
run: swift --version

- name: Build the modules and test targets that use no Apple framework
run: |
for target in AudioIO BroadcastWave OSC AutoGain Telemetry Destinations TakeFile Shows \
AudioIOTests OSCTests AutoGainTests TelemetryTests DestinationsTests ShowsTests; do
swift build --target "$target"
done
3 changes: 3 additions & 0 deletions Sources/Destinations/Destinations.swift
Original file line number Diff line number Diff line change
Expand Up @@ -110,6 +110,8 @@ public enum DriveStatus: Equatable, Sendable {
case unavailable(DriveProblem)
}

// Security-scoped bookmarks exist only in Apple's Foundation, so the store is left out elsewhere (Linux, #13).
#if canImport(Darwin)
/// The operator's Drive folder: chosen once, remembered with a security-scoped bookmark.
public struct DriveFolderStore: Sendable {
private let storage: any BookmarkStorage
Expand Down Expand Up @@ -267,6 +269,7 @@ public struct DriveFolderStore: Sendable {
return availableBytes(at: url)
}
}
#endif

/// The Drive folder opened for one Take, held until the Take is finalized and Repaired. `end()` lets it go
/// (for a bookmarked folder, its security scope).
Expand Down
3 changes: 3 additions & 0 deletions Tests/DestinationsTests/DriveFolderStoreTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@ import Destinations
import Foundation
import Testing

// `DriveFolderStore` is Apple-only (#13).
#if canImport(Darwin)
@Suite("Drive folder")
struct DriveFolderStoreTests {
let folder: URL
Expand Down Expand Up @@ -212,3 +214,4 @@ final class ThreadNotingStorage: BookmarkStorage, @unchecked Sendable {
}
func save(_ folder: StoredDriveFolder?) {}
}
#endif
Loading