Skip to content
Snippets Groups Projects
Commit c123ebca authored by Dariusz Rybicki's avatar Dariusz Rybicki
Browse files

Add Swift Package for example app

parent d4c6720c
No related branches found
No related tags found
1 merge request!1Client management
......@@ -7,18 +7,15 @@
objects = {
/* Begin PBXBuildFile section */
312C371A28475E62003E9E39 /* App.swift in Sources */ = {isa = PBXBuildFile; fileRef = 312C371928475E62003E9E39 /* App.swift */; };
312C371C28475E62003E9E39 /* ContentView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 312C371B28475E62003E9E39 /* ContentView.swift */; };
312C371E28475E63003E9E39 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 312C371D28475E63003E9E39 /* Assets.xcassets */; };
312C372C28476503003E9E39 /* ElixxirDAppsSDK in Frameworks */ = {isa = PBXBuildFile; productRef = 312C372B28476503003E9E39 /* ElixxirDAppsSDK */; };
316D95EE28477B0E008475F9 /* AppFeature in Frameworks */ = {isa = PBXBuildFile; productRef = 316D95ED28477B0E008475F9 /* AppFeature */; };
/* End PBXBuildFile section */
/* Begin PBXFileReference section */
312C371628475E62003E9E39 /* dApps Example.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = "dApps Example.app"; sourceTree = BUILT_PRODUCTS_DIR; };
312C371928475E62003E9E39 /* App.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = App.swift; sourceTree = "<group>"; };
312C371B28475E62003E9E39 /* ContentView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ContentView.swift; sourceTree = "<group>"; };
312C371D28475E63003E9E39 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = "<group>"; };
312C3728284761DC003E9E39 /* Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; };
316D95EB28477ACA008475F9 /* ExampleApp */ = {isa = PBXFileReference; lastKnownFileType = wrapper; path = ExampleApp; sourceTree = "<group>"; };
31B3342F2847669900865D82 /* ExampleAppIcon */ = {isa = PBXFileReference; lastKnownFileType = wrapper; path = ExampleAppIcon; sourceTree = "<group>"; };
/* End PBXFileReference section */
......@@ -27,7 +24,7 @@
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
312C372C28476503003E9E39 /* ElixxirDAppsSDK in Frameworks */,
316D95EE28477B0E008475F9 /* AppFeature in Frameworks */,
);
runOnlyForDeploymentPostprocessing = 0;
};
......@@ -38,6 +35,7 @@
isa = PBXGroup;
children = (
312C3727284761C7003E9E39 /* ExampleApp (iOS) */,
316D95EB28477ACA008475F9 /* ExampleApp */,
31B3342F2847669900865D82 /* ExampleAppIcon */,
312C371728475E62003E9E39 /* Products */,
);
......@@ -54,8 +52,6 @@
312C3727284761C7003E9E39 /* ExampleApp (iOS) */ = {
isa = PBXGroup;
children = (
312C371928475E62003E9E39 /* App.swift */,
312C371B28475E62003E9E39 /* ContentView.swift */,
312C371D28475E63003E9E39 /* Assets.xcassets */,
312C3728284761DC003E9E39 /* Info.plist */,
);
......@@ -79,7 +75,7 @@
);
name = "ExampleApp (iOS)";
packageProductDependencies = (
312C372B28476503003E9E39 /* ElixxirDAppsSDK */,
316D95ED28477B0E008475F9 /* AppFeature */,
);
productName = ExampleApp;
productReference = 312C371628475E62003E9E39 /* dApps Example.app */;
......@@ -134,8 +130,6 @@
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
312C371C28475E62003E9E39 /* ContentView.swift in Sources */,
312C371A28475E62003E9E39 /* App.swift in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
......@@ -340,9 +334,9 @@
/* End XCConfigurationList section */
/* Begin XCSwiftPackageProductDependency section */
312C372B28476503003E9E39 /* ElixxirDAppsSDK */ = {
316D95ED28477B0E008475F9 /* AppFeature */ = {
isa = XCSwiftPackageProductDependency;
productName = ElixxirDAppsSDK;
productName = AppFeature;
};
/* End XCSwiftPackageProductDependency section */
};
......
.DS_Store
/.build
/Packages
/*.xcodeproj
xcuserdata/
DerivedData/
.swiftpm/config/registries.json
.swiftpm/xcode/package.xcworkspace/contents.xcworkspacedata
.netrc
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1340"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "AppFeature"
BuildableName = "AppFeature"
BlueprintName = "AppFeature"
ReferencedContainer = "container:">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
</BuildAction>
<TestAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES"
codeCoverageEnabled = "YES">
<Testables>
<TestableReference
skipped = "NO">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "AppFeatureTests"
BuildableName = "AppFeatureTests"
BlueprintName = "AppFeatureTests"
ReferencedContainer = "container:">
</BuildableReference>
</TestableReference>
</Testables>
</TestAction>
<LaunchAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
debugServiceExtension = "internal"
allowLocationSimulation = "YES">
</LaunchAction>
<ProfileAction
buildConfiguration = "Release"
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
debugDocumentVersioning = "YES">
<MacroExpansion>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "AppFeature"
BuildableName = "AppFeature"
BlueprintName = "AppFeature"
ReferencedContainer = "container:">
</BuildableReference>
</MacroExpansion>
</ProfileAction>
<AnalyzeAction
buildConfiguration = "Debug">
</AnalyzeAction>
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
</ArchiveAction>
</Scheme>
// swift-tools-version: 5.6
import PackageDescription
let package = Package(
name: "ExampleApp",
platforms: [
.iOS(.v15),
],
products: [
.library(
name: "AppFeature",
targets: ["AppFeature"]
),
],
dependencies: [
.package(path: "../../"), // elixxir-dapps-sdk-swift
],
targets: [
.target(
name: "AppFeature",
dependencies: [
.product(
name: "ElixxirDAppsSDK",
package: "elixxir-dapps-sdk-swift"
),
]
),
.testTarget(
name: "AppFeatureTests",
dependencies: [
.target(name: "AppFeature"),
]
),
]
)
......@@ -4,7 +4,7 @@ import SwiftUI
struct App: SwiftUI.App {
var body: some Scene {
WindowGroup {
ContentView()
AppView()
}
}
}
import SwiftUI
struct ContentView: View {
struct AppView: View {
var body: some View {
Text("Hello, world!")
Text("AppView")
.padding()
}
}
#if DEBUG
struct ContentView_Previews: PreviewProvider {
struct AppView_Previews: PreviewProvider {
static var previews: some View {
ContentView()
AppView()
}
}
#endif
import XCTest
@testable import AppFeature
final class AppFeatureTests: XCTestCase {
func testExample() throws {
XCTAssert(true)
}
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment