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

V1.0.0 alpha.1 #1

Merged
merged 11 commits into from
Oct 22, 2024
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
39 changes: 39 additions & 0 deletions .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
{
"name": "Swift",
"image": "swift:6.0",
"features": {
"ghcr.io/devcontainers/features/common-utils:2": {
"installZsh": "false",
"username": "vscode",
"upgradePackages": "false"
},
"ghcr.io/devcontainers/features/git:1": {
"version": "os-provided",
"ppa": "false"
}
},
"runArgs": [
"--cap-add=SYS_PTRACE",
"--security-opt",
"seccomp=unconfined"
],
// Configure tool-specific properties.
"customizations": {
// Configure properties specific to VS Code.
"vscode": {
// Set *default* container specific settings.json values on container create.
"settings": {
"lldb.library": "/usr/lib/liblldb.so"
},
// Add the IDs of extensions you want installed when the container is created.
"extensions": [
"sswg.swift-lang"
]
}
},
// Use 'forwardPorts' to make a list of ports inside the container available locally.
// "forwardPorts": [],

// Set `remoteUser` to `root` to connect as root instead. More info: https://aka.ms/vscode-remote/containers/non-root.
"remoteUser": "vscode"
}
39 changes: 39 additions & 0 deletions .devcontainer/swift-5.8/devcontainer.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
{
"name": "Swift",
"image": "swift:5.8",
"features": {
"ghcr.io/devcontainers/features/common-utils:2": {
"installZsh": "false",
"username": "vscode",
"upgradePackages": "false"
},
"ghcr.io/devcontainers/features/git:1": {
"version": "os-provided",
"ppa": "false"
}
},
"runArgs": [
"--cap-add=SYS_PTRACE",
"--security-opt",
"seccomp=unconfined"
],
// Configure tool-specific properties.
"customizations": {
// Configure properties specific to VS Code.
"vscode": {
// Set *default* container specific settings.json values on container create.
"settings": {
"lldb.library": "/usr/lib/liblldb.so"
},
// Add the IDs of extensions you want installed when the container is created.
"extensions": [
"sswg.swift-lang"
]
}
},
// Use 'forwardPorts' to make a list of ports inside the container available locally.
// "forwardPorts": [],

// Set `remoteUser` to `root` to connect as root instead. More info: https://aka.ms/vscode-remote/containers/non-root.
"remoteUser": "root"
}
39 changes: 39 additions & 0 deletions .devcontainer/swift-6.0/devcontainer.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
{
"name": "Swift",
"image": "swift:6.0",
"features": {
"ghcr.io/devcontainers/features/common-utils:2": {
"installZsh": "false",
"username": "vscode",
"upgradePackages": "false"
},
"ghcr.io/devcontainers/features/git:1": {
"version": "os-provided",
"ppa": "false"
}
},
"runArgs": [
"--cap-add=SYS_PTRACE",
"--security-opt",
"seccomp=unconfined"
],
// Configure tool-specific properties.
"customizations": {
// Configure properties specific to VS Code.
"vscode": {
// Set *default* container specific settings.json values on container create.
"settings": {
"lldb.library": "/usr/lib/liblldb.so"
},
// Add the IDs of extensions you want installed when the container is created.
"extensions": [
"sswg.swift-lang"
]
}
},
// Use 'forwardPorts' to make a list of ports inside the container available locally.
// "forwardPorts": [],

// Set `remoteUser` to `root` to connect as root instead. More info: https://aka.ms/vscode-remote/containers/non-root.
"remoteUser": "vscode"
}
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: FelinePine
name: FelinePineSwift
on:
push:
branches-ignore:
Expand All @@ -8,14 +8,19 @@ jobs:
build-ubuntu:
name: Build on Ubuntu
env:
PACKAGE_NAME: FelinePine
PACKAGE_NAME: FelinePineSwift
SWIFT_VER: ${{ matrix.swift-version }}
runs-on: ${{ matrix.runs-on }}
if: "!contains(github.event.head_commit.message, 'ci skip')"
strategy:
matrix:
runs-on: [ubuntu-20.04, ubuntu-22.04]
swift-version: [5.8.1, 5.9, "5.10", "6.0.1"]
runs-on: [ubuntu-20.04, ubuntu-22.04, ubuntu-24.04]
swift-version: [5.8.1, 5.9, "5.10.1", "6.0.1"]
exclude:
- runs-on: ubuntu-24.04
swift-version: 5.9
- runs-on: ubuntu-24.04
swift-version: 5.8.1
steps:
- uses: actions/checkout@v4
- name: Cache swift package modules
Expand Down Expand Up @@ -54,34 +59,20 @@ jobs:
- name: Build
run: swift build
- name: Run tests
run: swift test --enable-test-discovery --enable-code-coverage
- uses: sersoft-gmbh/swift-coverage-action@v4
id: coverage-files
with:
fail-on-empty-output: true
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v4
run: swift test --enable-code-coverage
- uses: vapor/[email protected]
with:
fail_ci_if_error: true
flags: swift-${{ matrix.swift-version }},ubuntu
verbose: true
token: ${{ secrets.CODECOV_TOKEN }}
files: ${{ join(fromJSON(steps.coverage-files.outputs.files), ',') }}
codecov_token: ${{ secrets.CODECOV_TOKEN }}
verbose: true
build-macos:
name: Build on macOS
env:
PACKAGE_NAME: FelinePine
PACKAGE_NAME: FelinePineSwift
runs-on: ${{ matrix.runs-on }}
if: "!contains(github.event.head_commit.message, 'ci skip')"
strategy:
matrix:
include:
- runs-on: macos-13
xcode: "/Applications/Xcode_14.3.1.app"
iOSVersion: "16.4"
watchOSVersion: "9.4"
watchName: "Apple Watch Series 5 (40mm)"
iPhoneName: "iPhone 14"
- runs-on: macos-13
xcode: "/Applications/Xcode_15.0.1.app"
iOSVersion: "17.0.1"
Expand All @@ -101,11 +92,11 @@ jobs:
watchName: "Apple Watch Series 9 (45mm)"
iPhoneName: "iPhone 15 Pro"
- runs-on: macos-15
xcode: "/Applications/Xcode_16.1.app"
iOSVersion: "18.0"
watchOSVersion: "11.0"
watchName: "Apple Watch Series 10 (42mm)"
iPhoneName: "iPhone 16"
xcode: "/Applications/Xcode_16.1.app"
iOSVersion: "18.1"
watchOSVersion: "11.1"
watchName: "Apple Watch Series 10 (46mm)"
iPhoneName: "iPhone 16 Pro"
steps:
- uses: actions/checkout@v4
- name: Cache swift package modules
Expand Down Expand Up @@ -145,7 +136,7 @@ jobs:
- name: Build
run: swift build
- name: Run Swift Package tests
run: swift test -v --enable-code-coverage
run: swift test -v --enable-code-coverage
- uses: sersoft-gmbh/swift-coverage-action@v4
id: coverage-files-spm
with:
Expand All @@ -161,18 +152,8 @@ jobs:
- name: Lint
run: ./scripts/lint.sh
if: ${{ github.event_name == 'pull_request' && ( github.base_ref == 'main' || endsWith( github.ref_name , 'Prep') ) && matrix.xcode == '/Applications/Xcode_16.1.app' }}
- name: Dump PIF
if: startsWith(matrix.xcode,'/Applications/Xcode_14')
run: |
swift package dump-pif > /dev/null
MAX_ATTEMPT=3
ATTEMPT=0
while [ -z $SUCCESS ] && [ "$ATTEMPT" -le "$MAX_ATTEMPT" ]; do
xcodebuild clean -scheme FelinePine -destination 'generic/platform=iOS' | grep -q "CLEAN SUCCEEDED" && SUCCESS=true
ATTEMPT=$(($ATTEMPT+1))
done
- name: Run iOS target tests
run: xcodebuild test -scheme FelinePine -sdk iphonesimulator -destination 'platform=iOS Simulator,name=${{ matrix.iPhoneName }},OS=${{ matrix.iOSVersion }}' -enableCodeCoverage YES build test
run: xcodebuild test -scheme FelinePineSwift -sdk iphonesimulator -destination 'platform=iOS Simulator,name=${{ matrix.iPhoneName }},OS=${{ matrix.iOSVersion }}' -enableCodeCoverage YES build test
- uses: sersoft-gmbh/swift-coverage-action@v4
id: coverage-files-iOS
with:
Expand All @@ -186,7 +167,7 @@ jobs:
files: ${{ join(fromJSON(steps.coverage-files-iOS.outputs.files), ',') }}
flags: iOS,iOS${{ matrix.iOSVersion }},macOS,${{ env.XCODE_NAME }}
- name: Run watchOS target tests
run: xcodebuild test -scheme FelinePine -sdk watchsimulator -destination 'platform=watchOS Simulator,name=${{ matrix.watchName }},OS=${{ matrix.watchOSVersion }}' -enableCodeCoverage YES build test
run: xcodebuild test -scheme FelinePineSwift -sdk watchsimulator -destination 'platform=watchOS Simulator,name=${{ matrix.watchName }},OS=${{ matrix.watchOSVersion }}' -enableCodeCoverage YES build test
- uses: sersoft-gmbh/swift-coverage-action@v4
id: coverage-files-watchOS
with:
Expand Down
2 changes: 0 additions & 2 deletions .periphery.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1 @@
retain_public: true
targets:
- FelinePine
23 changes: 23 additions & 0 deletions Package.resolved
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
{
"pins" : [
{
"identity" : "felinepine",
"kind" : "remoteSourceControl",
"location" : "https://github.com/brightdigit/FelinePine.git",
"state" : {
"revision" : "b89389fcf3f1100d0765a6a21244df02b00fbc9e",
"version" : "1.0.0-beta.5"
}
},
{
"identity" : "swift-log",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-log.git",
"state" : {
"revision" : "9cb486020ebf03bfa5b5df985387a14a98744537",
"version" : "1.6.1"
}
}
],
"version" : 2
}
23 changes: 16 additions & 7 deletions Package.swift
Original file line number Diff line number Diff line change
Expand Up @@ -4,17 +4,25 @@
import PackageDescription

let package = Package(
name: "FelinePine",
name: "FelinePineSwift",
platforms: [.iOS(.v14), .watchOS(.v7), .macOS(.v11)],
products: [
.library(
name: "FelinePine",
targets: ["FelinePine"]
name: "FelinePineSwift",
targets: ["FelinePineSwift"]
)
],
dependencies: [
.package(url: "https://github.com/brightdigit/FelinePine.git", from: "1.0.0-beta.5"),
.package(url: "https://github.com/apple/swift-log.git", from: "1.0.0")
],
targets: [
.target(
name: "FelinePine",
name: "FelinePineSwift",
dependencies: [
"FelinePine",
.product(name: "Logging", package: "swift-log")
],
swiftSettings: [
SwiftSetting.enableUpcomingFeature("BareSlashRegexLiterals"),
SwiftSetting.enableUpcomingFeature("ConciseMagicFile"),
Expand All @@ -23,12 +31,13 @@ let package = Package(
SwiftSetting.enableUpcomingFeature("ImplicitOpenExistentials"),
SwiftSetting.enableUpcomingFeature("StrictConcurrency"),
SwiftSetting.enableUpcomingFeature("DisableOutwardActorInference"),
SwiftSetting.enableExperimentalFeature("StrictConcurrency")
SwiftSetting.enableExperimentalFeature("StrictConcurrency"),
SwiftSetting.enableExperimentalFeature("AccessLevelOnImport")
]
),
.testTarget(
name: "FelinePineTests",
dependencies: ["FelinePine"]
name: "FelinePineSwiftTests",
dependencies: ["FelinePineSwift"]
)
]
)
Expand Down
20 changes: 14 additions & 6 deletions [email protected]
Original file line number Diff line number Diff line change
Expand Up @@ -29,22 +29,30 @@ let swiftSettings: [SwiftSetting] = [
]

let package = Package(
name: "FelinePine",
name: "FelinePineSwift",
platforms: [.iOS(.v14), .watchOS(.v7), .macOS(.v11)],
products: [
.library(
name: "FelinePine",
targets: ["FelinePine"]
name: "FelinePineSwift",
targets: ["FelinePineSwift"]
)
],
dependencies: [
.package(url: "https://github.com/brightdigit/FelinePine.git", from: "1.0.0-beta.5"),
.package(url: "https://github.com/apple/swift-log.git", from: "1.0.0")
],
targets: [
.target(
name: "FelinePine",
name: "FelinePineSwift",
dependencies: [
"FelinePine",
.product(name: "Logging", package: "swift-log")
],
swiftSettings: swiftSettings
),
.testTarget(
name: "FelinePineTests",
dependencies: ["FelinePine"]
name: "FelinePineSwiftTests",
dependencies: ["FelinePineSwift"]
)
]
)
Expand Down
Loading
Loading