Skip to content
12 changes: 5 additions & 7 deletions .github/workflows/ios-tests.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
name: iOS Tests

on:
push:
branches: [ main ]
pull_request:
branches: [ main ]

Expand Down Expand Up @@ -30,8 +28,8 @@ jobs:
strategy:
fail-fast: false
matrix:
xcode: [ "16.0", "16.1" ]
os: [ macos-14, macos-15 ]
xcode: [ "16.3", "16.4" ] # "26.0" is broken with xcodebuild test
os: [ macos-15 ]
runs-on: ${{ matrix.os }}

env:
Expand All @@ -44,14 +42,14 @@ jobs:
run: |
set -o pipefail && \
NSUnbufferedIO=YES \
xcrun xcodebuild test -workspace . -scheme Vexil -skipMacroValidation -destination "platform=iOS Simulator,name=iPhone 16" \
xcrun xcodebuild test -workspace . -scheme Vexil -skipMacroValidation -destination "platform=iOS Simulator,name=iPhone 16e" \
| xcbeautify --renderer github-actions

build-ios:
runs-on: ubuntu-latest
name: iOS Tests
if: ${{ github.event_name == 'push' || needs.check-changes.outputs.changed == 'true' }}
needs: build-ios-matrix
if: ${{ always() && needs.check-changes.outputs.changed == 'true' }}
needs: [ build-ios-matrix, check-changes ]
steps:
- name: Check build matrix status
if: ${{ needs.build-ios-matrix.result != 'success' }}
Expand Down
10 changes: 4 additions & 6 deletions .github/workflows/linux-tests.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
name: Linux Tests

on:
push:
branches: [ main ]
pull_request:
branches: [ main ]

Expand Down Expand Up @@ -35,8 +33,8 @@ jobs:
strategy:
fail-fast: false
matrix:
swift: [ "swift:6.0.2" ]
os: [ amazonlinux2, focal, jammy, rhel-ubi9, noble ]
swift: [ "swift:6.1", "swift:6.2" ]
os: [ amazonlinux2, jammy, rhel-ubi9, noble ]

container:
image: ${{ matrix.swift }}-${{ matrix.os }}
Expand All @@ -50,8 +48,8 @@ jobs:
test:
runs-on: ubuntu-latest
name: Linux Tests
if: ${{ github.event_name == 'push' || needs.check-changes.outputs.changed == 'true' }}
needs: matrix
if: ${{ always() && needs.check-changes.outputs.changed == 'true' }}
needs: [ matrix, check-changes ]
steps:
- name: Check build matrix status
if: ${{ needs.matrix.result != 'success' }}
Expand Down
10 changes: 4 additions & 6 deletions .github/workflows/macos-tests.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
name: macOS Tests

on:
push:
branches: [ main ]
pull_request:
branches: [ main ]

Expand Down Expand Up @@ -30,8 +28,8 @@ jobs:
strategy:
fail-fast: false
matrix:
xcode: [ "16.0", "16.1" ]
os: [ macos-14, macos-15 ]
xcode: [ "16.3", "16.4", "26.0" ]
os: [ macos-15 ]
runs-on: ${{ matrix.os }}

env:
Expand All @@ -50,8 +48,8 @@ jobs:
build-macos:
runs-on: ubuntu-latest
name: macOS Tests
if: ${{ github.event_name == 'push' || needs.check-changes.outputs.changed == 'true' }}
needs: build-macos-matrix
if: ${{ always() && needs.check-changes.outputs.changed == 'true' }}
needs: [ build-macos-matrix, check-changes ]
steps:
- name: Check build matrix status
if: ${{ needs.build-macos-matrix.result != 'success' }}
Expand Down
10 changes: 4 additions & 6 deletions .github/workflows/tvos-tests.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
name: tvOS Tests

on:
push:
branches: [ main ]
pull_request:
branches: [ main ]

Expand Down Expand Up @@ -30,8 +28,8 @@ jobs:
strategy:
fail-fast: false
matrix:
xcode: [ "16.0", "16.1" ]
os: [ macos-14, macos-15 ]
xcode: [ "16.3", "16.4" ] # "26.0" is broken with xcodebuild test
os: [ macos-15 ]
runs-on: ${{ matrix.os }}

env:
Expand All @@ -50,8 +48,8 @@ jobs:
build-tvos:
runs-on: ubuntu-latest
name: tvOS Tests
if: ${{ github.event_name == 'push' || needs.check-changes.outputs.changed == 'true' }}
needs: build-tvos-matrix
if: ${{ always() && needs.check-changes.outputs.changed == 'true' }}
needs: [ build-tvos-matrix, check-changes ]
steps:
- name: Check build matrix status
if: ${{ needs.build-tvos-matrix.result != 'success' }}
Expand Down
12 changes: 5 additions & 7 deletions .github/workflows/visionos-tests.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
name: visionOS Tests

on:
push:
branches: [ main ]
pull_request:
branches: [ main ]

Expand Down Expand Up @@ -30,8 +28,8 @@ jobs:
strategy:
fail-fast: false
matrix:
xcode: [ "16.0", "16.1" ]
os: [ macos-14, macos-15 ]
xcode: [ "16.3", "16.4" ] # "26.0" is broken with xcodebuild test
os: [ macos-15 ]
runs-on: ${{ matrix.os }}

env:
Expand All @@ -44,14 +42,14 @@ jobs:
run: |
set -o pipefail && \
NSUnbufferedIO=YES \
xcrun xcodebuild test -workspace . -scheme Vexil -skipMacroValidation -destination "platform=visionOS Simulator,name=Apple Vision Pro" \
xcrun xcodebuild test -workspace . -scheme Vexil -skipMacroValidation -destination "platform=visionOS Simulator,name=Apple Vision Pro,os=2.5" \
| xcbeautify --renderer github-actions

build-visionos:
runs-on: ubuntu-latest
name: visionOS Tests
if: ${{ github.event_name == 'push' || needs.check-changes.outputs.changed == 'true' }}
needs: build-visionos-matrix
if: ${{ always() && needs.check-changes.outputs.changed == 'true' }}
needs: [ build-visionos-matrix, check-changes ]
steps:
- name: Check build matrix status
if: ${{ needs.build-visionos-matrix.result != 'success' }}
Expand Down
10 changes: 4 additions & 6 deletions .github/workflows/watchos-tests.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
name: watchOS Build Tests

on:
push:
branches: [ main ]
pull_request:
branches: [ main ]

Expand Down Expand Up @@ -30,8 +28,8 @@ jobs:
strategy:
fail-fast: false
matrix:
xcode: [ "16.0", "16.1" ]
os: [ macos-14, macos-15 ]
xcode: [ "16.3", "16.4" ] # "26.0" is broken with xcodebuild test
os: [ macos-15 ]
runs-on: ${{ matrix.os }}

env:
Expand All @@ -50,8 +48,8 @@ jobs:
build-watchos:
runs-on: ubuntu-latest
name: watchOS Tests
if: ${{ github.event_name == 'push' || needs.check-changes.outputs.changed == 'true' }}
needs: build-watchos-matrix
if: ${{ always() && needs.check-changes.outputs.changed == 'true' }}
needs: [ build-watchos-matrix, check-changes ]
steps:
- name: Check build matrix status
if: ${{ needs.build-watchos-matrix.result != 'success' }}
Expand Down
94 changes: 29 additions & 65 deletions Package.swift
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// swift-tools-version:6.0
// swift-tools-version:6.1
// The swift-tools-version declares the minimum version of Swift required to build this package.

import CompilerPluginSupport
Expand All @@ -20,39 +20,33 @@ let package = Package(
// .library(name: "Vexillographer", targets: [ "Vexillographer" ]),
],

dependencies: .init {
Package.Dependency.package(url: "https://github.com/apple/swift-async-algorithms.git", from: "1.0.0")
Package.Dependency.package(url: "https://github.com/nicklockwood/SwiftFormat.git", from: "0.54.1")
Package.Dependency.package(url: "https://github.com/swiftlang/swift-syntax.git", .upToNextMajor(from: "600.0.1"))
},
dependencies: [
.package(url: "https://github.com/apple/swift-async-algorithms.git", from: "1.0.0"),
.package(url: "https://github.com/nicklockwood/SwiftFormat.git", from: "0.54.1"),
.package(url: "https://github.com/swiftlang/swift-syntax.git", "600.0.0" ..< "603.0.0"),
],

targets: .init {
targets: [

// Vexil

Target.target(
.target(
name: "Vexil",
dependencies: [
.target(name: "VexilMacros"),
.product(name: "AsyncAlgorithms", package: "swift-async-algorithms"),
],
swiftSettings: [
.swiftLanguageMode(.v6),
]
)
Target.testTarget(
),
.testTarget(
name: "VexilTests",
dependencies: .init {
Target.Dependency.target(name: "Vexil")
},
swiftSettings: [
.swiftLanguageMode(.v6),
dependencies: [
.target(name: "Vexil"),
]
)
),

// Vexillographer

// Target.target(
// .target(
// name: "Vexillographer",
// dependencies: [
// .target(name: "Vexil"),
Expand All @@ -61,66 +55,36 @@ let package = Package(

// Macros

Target.macro(
.macro(
name: "VexilMacros",
dependencies: [
.product(name: "SwiftCompilerPlugin", package: "swift-syntax"),
.product(name: "SwiftSyntax", package: "swift-syntax"),
.product(name: "SwiftSyntaxBuilder", package: "swift-syntax"),
.product(name: "SwiftSyntaxMacros", package: "swift-syntax"),
],
swiftSettings: [
.swiftLanguageMode(.v6),
]
)
),

#if !os(Linux)

// We can't disable macro validation using `swift test` so these are guaranteed to fail on Linux
Target.testTarget(
name: "VexilMacroTests",
dependencies: [
.target(name: "VexilMacros"),
.product(name: "SwiftSyntaxMacrosTestSupport", package: "swift-syntax"),
],
swiftSettings: [
.swiftLanguageMode(.v6),
]
)

#endif

},
],

swiftLanguageModes: [
.v6,
]

)

// MARK: - Helpers

@resultBuilder
enum CollectionBuilder<Element> {

typealias Component = [Element]

static func buildExpression(_ expression: Element) -> Component {
[expression]
}

static func buildBlock(_ components: Component...) -> Component {
components.flatMap { $0 }
}

static func buildLimitedAvailability(_ components: [Element]) -> Component {
components
}
#if !os(Linux)

}
// We can't disable macro validation using `swift test` so these are guaranteed to fail on Linux
package.targets.append(
.testTarget(
name: "VexilMacroTests",
dependencies: [
.target(name: "VexilMacros"),
.product(name: "SwiftSyntaxMacrosTestSupport", package: "swift-syntax"),
]
)
)

extension Array {
init(@CollectionBuilder<Element> collecting: () -> [Element]) {
self = collecting()
}
}
#endif
2 changes: 1 addition & 1 deletion Sources/Vexil/Configuration.swift
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
//
// This source file is part of the Vexil open source project
//
// Copyright (c) 2024 Unsigned Apps and the open source contributors.
// Copyright (c) 2025 Unsigned Apps and the open source contributors.
// Licensed under the MIT license
//
// See LICENSE for license information
Expand Down
2 changes: 1 addition & 1 deletion Sources/Vexil/Container.swift
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
//
// This source file is part of the Vexil open source project
//
// Copyright (c) 2024 Unsigned Apps and the open source contributors.
// Copyright (c) 2025 Unsigned Apps and the open source contributors.
// Licensed under the MIT license
//
// See LICENSE for license information
Expand Down
2 changes: 1 addition & 1 deletion Sources/Vexil/DisplayOptions.swift
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
//
// This source file is part of the Vexil open source project
//
// Copyright (c) 2024 Unsigned Apps and the open source contributors.
// Copyright (c) 2025 Unsigned Apps and the open source contributors.
// Licensed under the MIT license
//
// See LICENSE for license information
Expand Down
2 changes: 1 addition & 1 deletion Sources/Vexil/Flag.swift
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
//
// This source file is part of the Vexil open source project
//
// Copyright (c) 2024 Unsigned Apps and the open source contributors.
// Copyright (c) 2025 Unsigned Apps and the open source contributors.
// Licensed under the MIT license
//
// See LICENSE for license information
Expand Down
2 changes: 1 addition & 1 deletion Sources/Vexil/Group.swift
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
//
// This source file is part of the Vexil open source project
//
// Copyright (c) 2024 Unsigned Apps and the open source contributors.
// Copyright (c) 2025 Unsigned Apps and the open source contributors.
// Licensed under the MIT license
//
// See LICENSE for license information
Expand Down
2 changes: 1 addition & 1 deletion Sources/Vexil/KeyPath.swift
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
//
// This source file is part of the Vexil open source project
//
// Copyright (c) 2024 Unsigned Apps and the open source contributors.
// Copyright (c) 2025 Unsigned Apps and the open source contributors.
// Licensed under the MIT license
//
// See LICENSE for license information
Expand Down
Loading
Loading