Skip to content

Commit

Permalink
fix: Change project to CareKitEssentials (#6)
Browse files Browse the repository at this point in the history
* Change project to CareKitEssentials

* Update files

* Update ci.yml

* Update ci.yml

* Add test scheme

* Update ci.yml
  • Loading branch information
cbaker6 authored Jun 24, 2024
1 parent 92e8304 commit 5fd0c29
Show file tree
Hide file tree
Showing 54 changed files with 182 additions and 140 deletions.
10 changes: 5 additions & 5 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ on:
branches: [ main ]

env:
CI_XCODE_LATEST: '/Applications/Xcode_15.0.app/Contents/Developer'
CI_XCODE_LATEST: '/Applications/Xcode_15.4.app/Contents/Developer'

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
Expand All @@ -17,17 +17,17 @@ concurrency:
jobs:
test:
timeout-minutes: 15
runs-on: macos-13
runs-on: macos-14
strategy:
matrix:
destination: ['platform=iOS\ Simulator,name=iPhone\ 14\ Pro\ Max', 'platform=watchOS\ Simulator,name=Apple\ Watch\ Series\ 5\ \(40mm\)']
action: ['test']
steps:
- uses: actions/checkout@v4
- name: Use multiple cores
run: defaults write com.apple.dt.XCBuild EnableSwiftBuildSystemIntegration 1
- name: Install Swiftlint
run: brew install swiftlint
- name: Build-Test
run: set -o pipefail && env NSUnbufferedIO=YES xcodebuild -scheme CareKitUtilities -derivedDataPath DerivedData -destination ${{ matrix.destination }} ${{ matrix.action }} | xcpretty -c
run: set -o pipefail && env NSUnbufferedIO=YES xcodebuild -scheme CareKitEssentials -derivedDataPath DerivedData -destination ${{ matrix.destination }} ${{ matrix.action }} | xcpretty -c
env:
DEVELOPER_DIR: ${{ env.CI_XCODE_LATEST }}
- name: Prepare codecov
Expand Down

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
{
"originHash" : "c87ec1825dcb99b8039396a27422e8ddfb17b5cb16956d62241c21c379b37c2c",
"pins" : [
{
"identity" : "carekit",
"kind" : "remoteSourceControl",
"location" : "https://github.com/cbaker6/CareKit.git",
"state" : {
"revision" : "95135c84d3de05e8397bd3a493729876bffc060e",
"version" : "3.0.0-beta.8"
}
},
{
"identity" : "fhirmodels",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/FHIRModels.git",
"state" : {
"revision" : "e115442fb3c5d44ffb1dc9b4e039b77fd143ad96",
"version" : "0.4.0"
}
},
{
"identity" : "swift-async-algorithms",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-async-algorithms",
"state" : {
"revision" : "9cfed92b026c524674ed869a4ff2dcfdeedf8a2a",
"version" : "0.1.0"
}
},
{
"identity" : "swift-collections",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-collections.git",
"state" : {
"revision" : "937e904258d22af6e447a0b72c0bc67583ef64a2",
"version" : "1.0.4"
}
}
],
"version" : 3
}
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1430"
LastUpgradeVersion = "1540"
version = "1.7">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
buildImplicitDependencies = "YES"
buildArchitectures = "Automatic">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
Expand All @@ -14,10 +15,10 @@
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "carekitutilities::CareKitUtilities"
BuildableName = "CareKitUtilities.framework"
BlueprintName = "CareKitUtilities"
ReferencedContainer = "container:CareKitUtilities.xcodeproj">
BlueprintIdentifier = "carekitessentials::CareKitEssentials"
BuildableName = "CareKitEssentials.framework"
BlueprintName = "CareKitEssentials"
ReferencedContainer = "container:CareKitEssentials.xcodeproj">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
Expand All @@ -29,8 +30,7 @@
shouldUseLaunchSchemeArgsEnv = "YES">
<TestPlans>
<TestPlanReference
reference = "container:CareKitUtilities.xctestplan"
default = "YES">
reference = "container:CareKitEssentials.xctestplan">
</TestPlanReference>
</TestPlans>
</TestAction>
Expand All @@ -54,10 +54,10 @@
<MacroExpansion>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "carekitutilities::CareKitUtilities"
BuildableName = "CareKitUtilities.framework"
BlueprintName = "CareKitUtilities"
ReferencedContainer = "container:CareKitUtilities.xcodeproj">
BlueprintIdentifier = "carekitessentials::CareKitEssentials"
BuildableName = "CareKitEssentials.framework"
BlueprintName = "CareKitEssentials"
ReferencedContainer = "container:CareKitEssentials.xcodeproj">
</BuildableReference>
</MacroExpansion>
</ProfileAction>
Expand Down
6 changes: 3 additions & 3 deletions CareKitUtilities.xctestplan → CareKitEssentials.xctestplan
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,9 @@
"testTargets" : [
{
"target" : {
"containerPath" : "container:CareKitUtilities.xcodeproj",
"identifier" : "carekitutilities::CareKitUtilitiesTests",
"name" : "CareKitUtilitiesTests"
"containerPath" : "container:CareKitEssentials.xcodeproj",
"identifier" : "carekitessentials::CareKitEssentialsTests",
"name" : "CareKitEssentialsTests"
}
}
],
Expand Down
4 changes: 2 additions & 2 deletions Package.resolved
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@
"kind" : "remoteSourceControl",
"location" : "https://github.com/cbaker6/CareKit.git",
"state" : {
"revision" : "ed05957648de96d7ad8a81bd24edff3ee712f20e",
"version" : "3.0.0-beta.2"
"revision" : "95135c84d3de05e8397bd3a493729876bffc060e",
"version" : "3.0.0-beta.8"
}
},
{
Expand Down
14 changes: 7 additions & 7 deletions Package.swift
Original file line number Diff line number Diff line change
Expand Up @@ -3,27 +3,27 @@
import PackageDescription

let package = Package(
name: "CareKitUtilities",
name: "CareKitEssentials",
platforms: [.iOS(.v14), .macOS(.v13), .watchOS(.v7)],
products: [
.library(
name: "CareKitUtilities",
targets: ["CareKitUtilities"])
name: "CareKitEssentials",
targets: ["CareKitEssentials"])
],
dependencies: [
.package(url: "https://github.com/cbaker6/CareKit.git",
.upToNextMajor(from: "3.0.0-beta.2"))
.upToNextMajor(from: "3.0.0-beta.8"))
],
targets: [
.target(
name: "CareKitUtilities",
name: "CareKitEssentials",
dependencies: [
.product(name: "CareKit", package: "CareKit"),
.product(name: "CareKitStore", package: "CareKit"),
.product(name: "CareKitUI", package: "CareKit")
]),
.testTarget(
name: "CareKitUtilitiesTests",
dependencies: ["CareKitUtilities"])
name: "CareKitEssentialsTests",
dependencies: ["CareKitEssentials"])
]
)
10 changes: 5 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
# CareKitUtilities
# CareKitEssentials

[![](https://img.shields.io/endpoint?url=https%3A%2F%2Fswiftpackageindex.com%2Fapi%2Fpackages%2Fnetreconlab%2FCareKitUtilities%2Fbadge%3Ftype%3Dswift-versions)](https://swiftpackageindex.com/netreconlab/CareKitUtilities)
[![](https://img.shields.io/endpoint?url=https%3A%2F%2Fswiftpackageindex.com%2Fapi%2Fpackages%2Fnetreconlab%2FCareKitUtilities%2Fbadge%3Ftype%3Dplatforms)](https://swiftpackageindex.com/netreconlab/CareKitUtilities)
[![](https://img.shields.io/endpoint?url=https%3A%2F%2Fswiftpackageindex.com%2Fapi%2Fpackages%2Fnetreconlab%2FCareKitEssentials%2Fbadge%3Ftype%3Dswift-versions)](https://swiftpackageindex.com/netreconlab/CareKitEssentials)
[![](https://img.shields.io/endpoint?url=https%3A%2F%2Fswiftpackageindex.com%2Fapi%2Fpackages%2Fnetreconlab%2FCareKitEssentials%2Fbadge%3Ftype%3Dplatforms)](https://swiftpackageindex.com/netreconlab/CareKitEssentials)
![Xcode 13.2+](https://img.shields.io/badge/xcode-13.2%2B-blue.svg)
[![CI Status](https://github.com/netreconlab/CareKitUtilities/workflows/ci/badge.svg?branch=main)](https://github.com/netreconlab/CareKitUtilities/actions?query=workflow%3Aci)
![Codecov](https://codecov.io/gh/netreconlab/CareKitUtilities/branches/main/graph/badge.svg)
[![CI Status](https://github.com/netreconlab/CareKitEssentials/workflows/ci/badge.svg?branch=main)](https://github.com/netreconlab/CareKitEssentials/actions?query=workflow%3Aci)
![Codecov](https://codecov.io/gh/netreconlab/CareKitEssentials/branches/main/graph/badge.svg)
[![License](https://img.shields.io/badge/license-Apache%202.0-blue.svg)](https://github.com/netreconlab/ParseCareKit/#license)

A description of this package.
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
//
// CardViewModel.swift
// CareKitUtilities
// CareKitEssentials
//
// Created by Corey Baker on 12/4/22.
// Copyright © 2022 NetReconLab. All rights reserved.
Expand Down Expand Up @@ -161,7 +161,7 @@ open class CardViewModel: ObservableObject {
/// - values: The outcome values to attach to the outcome.
open func createOutcomeWithValues(_ values: [OCKOutcomeValue]) throws -> OCKAnyOutcome {
guard let task = event.task as? OCKAnyVersionableTask else {
throw CareKitUtilitiesError.errorString("Cannot make outcome for event: \(event)")
throw CareKitEssentialsError.errorString("Cannot make outcome for event: \(event)")
}
return OCKOutcome(taskUUID: task.uuid,
taskOccurrenceIndex: event.scheduleEvent.occurrence,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
//
// CustomLabelView.swift
// CareKitUtilities
// CareKitEssentials
//
// Created by Alyssa Donawa on 9/12/22.
// Copyright © 2022 NetReconLab. All rights reserved.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
//
// DetailsView.swift
// CareKitUtilities
// CareKitEssentials
//
// Created by Julia Stekardis on 12/6/22.
// Copyright © 2022 NetReconLab. All rights reserved.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
//
// InformationHeaderView.swift
// CareKitUtilities
// CareKitEssentials
//
// Created by Julia Stekardis on 12/6/22.
// Copyright © 2022 NetReconLab. All rights reserved.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
//
// InstructionsTaskView.swift
// CareKitUtilities
// CareKitEssentials
//
// Created by Corey Baker on 5/20/23.
//
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
//
// SimpleTaskView.swift
// CareKitUtilities
// CareKitEssentials
//
// Created by Corey Baker on 5/20/23.
//
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
//
// LabeledValueTaskView.swift
// CareKitUtilities
// CareKitEssentials
//
// Created by Corey Baker on 5/20/23.
//
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
//
// NumericProgressTaskView.swift
// CareKitUtilities
// CareKitEssentials
//
// Created by Corey Baker on 5/20/23.
//
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
//
// Slider.swift
// CareKitUtilities
// CareKitEssentials
//
// Created by Dylan Li on 6/22/20.
// Copyright © 2020 NetReconLab. All rights reserved.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
//
// SliderLogButton.swift
// CareKitUtilities
// CareKitEssentials
//
// Created by Dylan Li on 6/27/20.
// Copyright © 2020 NetReconLab. All rights reserved.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
//
// SliderLogTaskView.swift
// CareKitUtilities
// CareKitEssentials
//
// Created by Dylan Li on 6/2/20.
// Copyright © 2020 NetReconLab. All rights reserved.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
//
// SliderLogTaskViewModel.swift
// CareKitUtilities
// CareKitEssentials
//
// Created by Corey Baker on 5/16/23.
//
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
//
// DigitalCrownView.swift
// CareKitUtilities
// CareKitEssentials
//
// Created by Julia Stekardis on 12/1/22.
// Copyright © 2022 NetReconLab. All rights reserved.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
//
// DigitalCrownViewFooter.swift
// CareKitUtilities
// CareKitEssentials
//
// Created by Julia Stekardis on 12/1/22.
// Copyright © 2022 NetReconLab. All rights reserved.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
//
// DigitalCrownViewHeader.swift
// CareKitUtilities
// CareKitEssentials
//
// Created by Julia Stekardis on 12/1/22.
// Copyright © 2022 NetReconLab. All rights reserved.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
//
// DigitalCrownViewModel.swift
// CareKitUtilities
// CareKitEssentials
//
// Created by Julia Stekardis on 10/17/22.
// Copyright © 2022 NetReconLab. All rights reserved.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
//
// CardEnabledEnvironmentKey.swift
// CareKitUtilities
// CareKitEssentials
//
// Created by Corey Baker on 5/15/23.
//
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
//
// CGFloat.swift
// CareKitUtilities
// CareKitEssentials
//
// Created by Corey Baker on 12/4/22.
// Copyright © 2022 NetReconLab. All rights reserved.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
//
// Calendar+Dates.swift
// CareKitUtilities
// CareKitEssentials
//
// Created by Corey Baker on 10/16/21.
// Copyright © 2021 Network Reconnaissance Lab. All rights reserved.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
//
// Image.swift
// CareKitUtilities
// CareKitEssentials
//
// Created by Alyssa Donawa on 2/27/23.
// Copyright © 2023 NetReconLab. All rights reserved.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
//
// OCKAnyEvent+CustomStringConvertable.swift
// CareKitUtilities
// CareKitEssentials
//
// Created by Corey Baker on 1/5/22.
// Copyright © 2022 Network Reconnaissance Lab. All rights reserved.
Expand All @@ -14,12 +14,12 @@ extension OCKAnyEvent: CustomStringConvertible {
public var description: String {
guard let task = self.task as? OCKTask,
let encodedTask = try? JSONEncoder().encode(task),
let stringTask = String(data: encodedTask, encoding: .utf8),
let outcome = self.outcome as? OCKOutcome,
let encodedOutcome = try? JSONEncoder().encode(outcome),
let stringOutcome = String(data: encodedOutcome, encoding: .utf8) else {
let encodedOutcome = try? JSONEncoder().encode(outcome) else {
return ""
}
let stringTask = String(decoding: encodedTask, as: UTF8.self)
let stringOutcome = String(decoding: encodedOutcome, as: UTF8.self)
return stringTask + stringOutcome
}
}
Expand Down
Loading

0 comments on commit 5fd0c29

Please sign in to comment.