Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

V2.0.1 #56

Merged
merged 5 commits into from
Jan 11, 2025
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
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
140 changes: 84 additions & 56 deletions .github/workflows/BushelKit.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,81 +43,109 @@ jobs:
files: ${{ join(fromJSON(steps.coverage-files.outputs.files), ',') }}
build-macos:
name: Build on macOS
runs-on: [self-hosted, macOS]
env:
PACKAGE_NAME: BushelKit
runs-on: ${{ matrix.runs-on }}
if: "!contains(github.event.head_commit.message, 'ci skip')"
strategy:
fail-fast: false
matrix:
include:
# SPM Build Matrix
- runs-on: macos-15
xcode: "/Applications/Xcode_16.1.app"
- runs-on: macos-15
xcode: "/Applications/Xcode_16.2.app"

# iOS Build Matrix
- type: ios
runs-on: macos-15
xcode: "/Applications/Xcode_16.1.app"
deviceName: "iPhone 16"
osVersion: "18.1"
- type: ios
runs-on: macos-15
xcode: "/Applications/Xcode_16.2.app"
deviceName: "iPhone 16 Pro"
osVersion: "18.2"

# watchOS Build Matrix
- type: watchos
runs-on: macos-15
xcode: "/Applications/Xcode_16.1.app"
deviceName: "Apple Watch Ultra 2 (49mm)"
osVersion: "11.1"
- type: watchos
runs-on: macos-15
xcode: "/Applications/Xcode_16.2.app"
deviceName: "Apple Watch Ultra 2 (49mm)"
osVersion: "11.2"

- type: visionos
runs-on: macos-15
xcode: "/Applications/Xcode_16.2.app"
deviceName: "Apple Vision Pro"
osVersion: "2.2"

steps:
- uses: actions/checkout@v4

- name: Set Xcode Name
run: echo "XCODE_NAME=$(basename -- ${{ matrix.xcode }} | sed 's/\.[^.]*$//' | cut -d'_' -f2)" >> $GITHUB_ENV

- name: Setup Xcode
run: sudo xcode-select -s ${{ matrix.xcode }}/Contents/Developer

# SPM Cache Step
- name: Cache swift package modules
id: cache-spm-macos
uses: actions/cache@v4
env:
cache-name: cache-spm
with:
path: .build
key: ${{ matrix.os }}-build-${{ env.cache-name }}-Xcode16-${{ hashFiles('Package.resolved') }}
restore-keys: |
${{ matrix.os }}-build-${{ env.cache-name }}-Xcode16-
- name: Cache mint
id: cache-mint
uses: actions/cache@v4
env:
cache-name: cache-mint
with:
path: .mint
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('Mintfile') }}
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('Package.resolved') }}
restore-keys: |
${{ runner.os }}-build-${{ env.cache-name }}-
${{ runner.os }}-build-
${{ runner.os }}-
- name: Build

- name: Build SPM
if: "!matrix.type"
run: swift build

- name: Run Swift Package tests
run: swift test --enable-code-coverage
- uses: sersoft-gmbh/swift-coverage-action@v4
id: coverage-files-spm
with:
fail-on-empty-output: true
ignore-conversion-failures: true
- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v4
with:
files: ${{ join(fromJSON(steps.coverage-files-spm.outputs.files), ',') }}
token: ${{ secrets.CODECOV_TOKEN }}
flags: macOS,${{ env.XCODE_NAME }},macos
- name: Clean up spm build directory
run: rm -rf .build
- name: Lint
run: ./scripts/lint.sh
- name: Run iOS target tests
run: xcodebuild test -scheme BushelKit-Package -sdk iphonesimulator18.1 -destination "OS=18.1,name=iPhone 16" -enableCodeCoverage YES build test
- uses: sersoft-gmbh/swift-coverage-action@v4
id: coverage-files-iOS
with:
fail-on-empty-output: true
ignore-conversion-failures: true
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v4
if: "!matrix.type"
run: swift test -v --enable-code-coverage

- name: Enable Swift Testing
if: matrix.type
run: |
mkdir -p ~/Library/org.swift.swiftpm/security/
cp macros.json ~/Library/org.swift.swiftpm/security/

# Common iOS/watchOS Test Steps
- name: Run Device Tests
if: matrix.type
run: >
xcodebuild test
-scheme ${{ env.PACKAGE_NAME }}-Package
-sdk ${{ matrix.type == 'ios' && 'iphonesimulator' || matrix.type == 'watchos' && 'watchsimulator' || 'xrsimulator' }}
-destination 'platform=${{ matrix.type == 'ios' && 'iOS Simulator' || matrix.type == 'watchos' && 'watchOS Simulator' || 'visionOS Simulator' }},name=${{ matrix.deviceName }},OS=${{ matrix.osVersion }}'
-enableCodeCoverage YES
build test

# Common Coverage Steps
- name: Process Coverage
uses: sersoft-gmbh/swift-coverage-action@v4
with:
fail_ci_if_error: true
verbose: true
token: ${{ secrets.CODECOV_TOKEN }}
files: ${{ join(fromJSON(steps.coverage-files-iOS.outputs.files), ',') }}
flags: iOS,iOS18,macOS,Xcode16
- name: Run watchOS target tests
run: xcodebuild test -scheme BushelKit-Package -sdk watchsimulator11.1 -destination "OS=11.1,name=Apple Watch Series 10 (46mm)" -enableCodeCoverage YES build test
- uses: sersoft-gmbh/swift-coverage-action@v4
id: coverage-files-watchOS
with:
fail-on-empty-output: true
ignore-conversion-failures: true
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v4

- name: Upload Coverage
uses: codecov/codecov-action@v4
with:
fail_ci_if_error: true
verbose: true
token: ${{ secrets.CODECOV_TOKEN }}
files: ${{ join(fromJSON(steps.coverage-files-watchOS.outputs.files), ',') }}
flags: watchOS,watchOS11,macOS,Xcode16
token: ${{ secrets.CODECOV_TOKEN }}
flags: ${{ matrix.type && format('{0}{1}', matrix.type, matrix.osVersion) || 'spm' }}
build-docc:
name: Build DocC
needs: [build-macos, build-ubuntu]
Expand Down
1 change: 1 addition & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{}
1 change: 0 additions & 1 deletion Mintfile
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
dral3x/[email protected]
swiftlang/[email protected]
realm/[email protected]
a7ex/[email protected]
peripheryapp/[email protected]
6 changes: 3 additions & 3 deletions Package.resolved
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"originHash" : "d7930ff6269792b6bb007989a1d111f6b6d97ee38480575779f6b30ff3ac3027",
"originHash" : "f809a2c32ad5fa24ea844247b659272c2028e4a1b91ec708e451b3852ce74f9e",
"pins" : [
{
"identity" : "felinepine",
Expand Down Expand Up @@ -42,8 +42,8 @@
"kind" : "remoteSourceControl",
"location" : "https://github.com/brightdigit/RadiantKit.git",
"state" : {
"revision" : "aee29dc229e3107707ea029ddf9e9d5924dafa6d",
"version" : "1.0.0-alpha.4"
"revision" : "65b8a9ad7499372d2289ad53135adaafb24ee92c",
"version" : "1.0.0-beta.1"
}
},
{
Expand Down
2 changes: 1 addition & 1 deletion Package.swift
Original file line number Diff line number Diff line change
Expand Up @@ -963,7 +963,7 @@ var dependency: Package.Dependency {
}
struct RadiantKit: PackageDependency, TargetDependency {
var dependency: Package.Dependency {
.package(url: "https://github.com/brightdigit/RadiantKit.git", from: "1.0.0-alpha.4")
.package(url: "https://github.com/brightdigit/RadiantKit.git", from: "1.0.0-beta.1")
}
}
struct IPSWDownloads: PackageDependency, TargetDependency {
Expand Down
2 changes: 1 addition & 1 deletion Package/Sources/Dependencies/RadiantKit.swift
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,6 @@

struct RadiantKit: PackageDependency, TargetDependency {
var dependency: Package.Dependency {
.package(url: "https://github.com/brightdigit/RadiantKit.git", from: "1.0.0-alpha.4")
.package(url: "https://github.com/brightdigit/RadiantKit.git", from: "1.0.0-beta.1")
}
}
2 changes: 1 addition & 1 deletion Sources/BushelArgs/Bushel.swift
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
// BushelKit
//
// Created by Leo Dion.
// Copyright © 2024 BrightDigit.
// Copyright © 2025 BrightDigit.
//
// Permission is hereby granted, free of charge, to any person
// obtaining a copy of this software and associated documentation
Expand Down
2 changes: 1 addition & 1 deletion Sources/BushelArgs/BushelCommand.swift
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
// BushelKit
//
// Created by Leo Dion.
// Copyright © 2024 BrightDigit.
// Copyright © 2025 BrightDigit.
//
// Permission is hereby granted, free of charge, to any person
// obtaining a copy of this software and associated documentation
Expand Down
2 changes: 1 addition & 1 deletion Sources/BushelArgs/Image/Image.swift
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
// BushelKit
//
// Created by Leo Dion.
// Copyright © 2024 BrightDigit.
// Copyright © 2025 BrightDigit.
//
// Permission is hereby granted, free of charge, to any person
// obtaining a copy of this software and associated documentation
Expand Down
2 changes: 1 addition & 1 deletion Sources/BushelArgs/Image/List.swift
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
// BushelKit
//
// Created by Leo Dion.
// Copyright © 2024 BrightDigit.
// Copyright © 2025 BrightDigit.
//
// Permission is hereby granted, free of charge, to any person
// obtaining a copy of this software and associated documentation
Expand Down
2 changes: 1 addition & 1 deletion Sources/BushelArgs/Machine/Create.swift
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
// BushelKit
//
// Created by Leo Dion.
// Copyright © 2024 BrightDigit.
// Copyright © 2025 BrightDigit.
//
// Permission is hereby granted, free of charge, to any person
// obtaining a copy of this software and associated documentation
Expand Down
2 changes: 1 addition & 1 deletion Sources/BushelArgs/Machine/Machine.swift
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
// BushelKit
//
// Created by Leo Dion.
// Copyright © 2024 BrightDigit.
// Copyright © 2025 BrightDigit.
//
// Permission is hereby granted, free of charge, to any person
// obtaining a copy of this software and associated documentation
Expand Down
2 changes: 1 addition & 1 deletion Sources/BushelDocs/FileType.swift
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
// BushelKit
//
// Created by Leo Dion.
// Copyright © 2024 BrightDigit.
// Copyright © 2025 BrightDigit.
//
// Permission is hereby granted, free of charge, to any person
// obtaining a copy of this software and associated documentation
Expand Down
2 changes: 1 addition & 1 deletion Sources/BushelDocs/InitializablePackage.swift
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
// BushelKit
//
// Created by Leo Dion.
// Copyright © 2024 BrightDigit.
// Copyright © 2025 BrightDigit.
//
// Permission is hereby granted, free of charge, to any person
// obtaining a copy of this software and associated documentation
Expand Down
2 changes: 1 addition & 1 deletion Sources/BushelFactory/CalculationParameters.swift
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
// BushelKit
//
// Created by Leo Dion.
// Copyright © 2024 BrightDigit.
// Copyright © 2025 BrightDigit.
//
// Permission is hereby granted, free of charge, to any person
// obtaining a copy of this software and associated documentation
Expand Down
2 changes: 1 addition & 1 deletion Sources/BushelFactory/ConfigurationError.swift
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
// BushelKit
//
// Created by Leo Dion.
// Copyright © 2024 BrightDigit.
// Copyright © 2025 BrightDigit.
//
// Permission is hereby granted, free of charge, to any person
// obtaining a copy of this software and associated documentation
Expand Down
2 changes: 1 addition & 1 deletion Sources/BushelFactory/CustomRelease.swift
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
// BushelKit
//
// Created by Leo Dion.
// Copyright © 2024 BrightDigit.
// Copyright © 2025 BrightDigit.
//
// Permission is hereby granted, free of charge, to any person
// obtaining a copy of this software and associated documentation
Expand Down
2 changes: 1 addition & 1 deletion Sources/BushelFactory/InstallerImage.Metadata.swift
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
// BushelKit
//
// Created by Leo Dion.
// Copyright © 2024 BrightDigit.
// Copyright © 2025 BrightDigit.
//
// Permission is hereby granted, free of charge, to any person
// obtaining a copy of this software and associated documentation
Expand Down
2 changes: 1 addition & 1 deletion Sources/BushelFactory/MachineConfigurable.swift
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
// BushelKit
//
// Created by Leo Dion.
// Copyright © 2024 BrightDigit.
// Copyright © 2025 BrightDigit.
//
// Permission is hereby granted, free of charge, to any person
// obtaining a copy of this software and associated documentation
Expand Down
2 changes: 1 addition & 1 deletion Sources/BushelFactory/MachineConfiguration.swift
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
// BushelKit
//
// Created by Leo Dion.
// Copyright © 2024 BrightDigit.
// Copyright © 2025 BrightDigit.
//
// Permission is hereby granted, free of charge, to any person
// obtaining a copy of this software and associated documentation
Expand Down
2 changes: 1 addition & 1 deletion Sources/BushelFactory/ReleaseCollection.swift
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
// BushelKit
//
// Created by Leo Dion.
// Copyright © 2024 BrightDigit.
// Copyright © 2025 BrightDigit.
//
// Permission is hereby granted, free of charge, to any person
// obtaining a copy of this software and associated documentation
Expand Down
2 changes: 1 addition & 1 deletion Sources/BushelFactory/ReleaseMetadata.swift
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
// BushelKit
//
// Created by Leo Dion.
// Copyright © 2024 BrightDigit.
// Copyright © 2025 BrightDigit.
//
// Permission is hereby granted, free of charge, to any person
// obtaining a copy of this software and associated documentation
Expand Down
2 changes: 1 addition & 1 deletion Sources/BushelFactory/ReleaseQueryResult.swift
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
// BushelKit
//
// Created by Leo Dion.
// Copyright © 2024 BrightDigit.
// Copyright © 2025 BrightDigit.
//
// Permission is hereby granted, free of charge, to any person
// obtaining a copy of this software and associated documentation
Expand Down
2 changes: 1 addition & 1 deletion Sources/BushelFactory/ReleaseSelected.swift
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
// BushelKit
//
// Created by Leo Dion.
// Copyright © 2024 BrightDigit.
// Copyright © 2025 BrightDigit.
//
// Permission is hereby granted, free of charge, to any person
// obtaining a copy of this software and associated documentation
Expand Down
2 changes: 1 addition & 1 deletion Sources/BushelFactory/SelectedVersion.swift
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
// BushelKit
//
// Created by Leo Dion.
// Copyright © 2024 BrightDigit.
// Copyright © 2025 BrightDigit.
//
// Permission is hereby granted, free of charge, to any person
// obtaining a copy of this software and associated documentation
Expand Down
Loading
Loading