Skip to content

Commit

Permalink
Merge pull request #45 from nakajijapan/use-swift-package
Browse files Browse the repository at this point in the history
Use Swift Package Management
  • Loading branch information
nakajijapan authored Jul 29, 2021
2 parents 52c124e + b55f367 commit fb98039
Show file tree
Hide file tree
Showing 9 changed files with 106 additions and 57 deletions.
18 changes: 13 additions & 5 deletions Package.swift
Original file line number Diff line number Diff line change
@@ -1,10 +1,18 @@
// swift-tools-version:5.0

// swift-tools-version:5.4.0
import PackageDescription

let package = Package(
name: "Shari",
platforms: [.iOS(.v10)],
products: [.library(name: "Shari", targets: ["Shari"])],
targets: [.target(name: "Shari", path: "Sources")]
platforms: [.iOS(.v13)],
products: [
.library(name: "Shari", targets: ["Shari"])
],
dependencies: [],
targets: [
.target(
name: "Shari",
dependencies: [],
path: "Sources"
)
]
)
76 changes: 56 additions & 20 deletions Shari-Demo.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,14 @@
archiveVersion = 1;
classes = {
};
objectVersion = 46;
objectVersion = 52;
objects = {

/* Begin PBXBuildFile section */
B012C9D726B2957F00914DF2 /* Shari in Frameworks */ = {isa = PBXBuildFile; productRef = B012C9D626B2957F00914DF2 /* Shari */; };
B0132F292329008100413D0A /* LineView.swift in Sources */ = {isa = PBXBuildFile; fileRef = B0132F282329008100413D0A /* LineView.swift */; };
B0132F2C2329029300413D0A /* ModalV2TableViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = B0132F2B2329029300413D0A /* ModalV2TableViewController.swift */; };
B0132F2E232A0ACF00413D0A /* LineButton.swift in Sources */ = {isa = PBXBuildFile; fileRef = B0132F2D232A0ACF00413D0A /* LineButton.swift */; };
B0132F33232A17CF00413D0A /* Shari.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = B0132F32232A17CF00413D0A /* Shari.framework */; };
B0132F34232A17CF00413D0A /* Shari.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = B0132F32232A17CF00413D0A /* Shari.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; };
B0A0CA5A1FC7010A00D132C9 /* README.md in Resources */ = {isa = PBXBuildFile; fileRef = B0A0CA591FC7010A00D132C9 /* README.md */; };
B0A0CA5D1FC708B200D132C9 /* .swiftlint.yml in Resources */ = {isa = PBXBuildFile; fileRef = B0A0CA5B1FC708B200D132C9 /* .swiftlint.yml */; };
B0A0CA5E1FC708B200D132C9 /* .travis.yml in Resources */ = {isa = PBXBuildFile; fileRef = B0A0CA5C1FC708B200D132C9 /* .travis.yml */; };
Expand Down Expand Up @@ -48,7 +47,6 @@
dstPath = "";
dstSubfolderSpec = 10;
files = (
B0132F34232A17CF00413D0A /* Shari.framework in Embed Frameworks */,
);
name = "Embed Frameworks";
runOnlyForDeploymentPostprocessing = 0;
Expand All @@ -59,8 +57,6 @@
B0132F282329008100413D0A /* LineView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = LineView.swift; sourceTree = "<group>"; };
B0132F2B2329029300413D0A /* ModalV2TableViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ModalV2TableViewController.swift; sourceTree = "<group>"; };
B0132F2D232A0ACF00413D0A /* LineButton.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = LineButton.swift; sourceTree = "<group>"; };
B0132F2F232A0DEC00413D0A /* Shari.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; path = Shari.framework; sourceTree = BUILT_PRODUCTS_DIR; };
B0132F32232A17CF00413D0A /* Shari.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; path = Shari.framework; sourceTree = BUILT_PRODUCTS_DIR; };
B0A0CA591FC7010A00D132C9 /* README.md */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = net.daringfireball.markdown; path = README.md; sourceTree = "<group>"; };
B0A0CA5B1FC708B200D132C9 /* .swiftlint.yml */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = .swiftlint.yml; sourceTree = "<group>"; };
B0A0CA5C1FC708B200D132C9 /* .travis.yml */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = .travis.yml; sourceTree = "<group>"; };
Expand Down Expand Up @@ -96,7 +92,7 @@
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
B0132F33232A17CF00413D0A /* Shari.framework in Frameworks */,
B012C9D726B2957F00914DF2 /* Shari in Frameworks */,
);
runOnlyForDeploymentPostprocessing = 0;
};
Expand Down Expand Up @@ -170,8 +166,6 @@
DC9E67F11C3005070095C3AB = {
isa = PBXGroup;
children = (
B0132F32232A17CF00413D0A /* Shari.framework */,
B0132F2F232A0DEC00413D0A /* Shari.framework */,
B0A0CA581FC700F800D132C9 /* MetaData */,
DC9E67FC1C3005070095C3AB /* Shari-Demo */,
DC54326B1C62214300612AE3 /* Shari-DemoUITests */,
Expand Down Expand Up @@ -243,6 +237,9 @@
dependencies = (
);
name = "Shari-Demo";
packageProductDependencies = (
B012C9D626B2957F00914DF2 /* Shari */,
);
productName = "Shari-Demo";
productReference = DC9E67FA1C3005070095C3AB /* Shari-Demo.app */;
productType = "com.apple.product-type.application";
Expand All @@ -254,7 +251,7 @@
isa = PBXProject;
attributes = {
LastSwiftUpdateCheck = 0720;
LastUpgradeCheck = 1030;
LastUpgradeCheck = 1250;
ORGANIZATIONNAME = nakajijapan;
TargetAttributes = {
DC5432691C62214300612AE3 = {
Expand All @@ -277,6 +274,9 @@
Base,
);
mainGroup = DC9E67F11C3005070095C3AB;
packageReferences = (
B012C9D526B2957F00914DF2 /* XCRemoteSwiftPackageReference "Shari" */,
);
productRefGroup = DC9E67FB1C3005070095C3AB /* Products */;
projectDirPath = "";
projectRoot = "";
Expand Down Expand Up @@ -323,7 +323,7 @@
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
shellScript = "if which swiftlint >/dev/null; then\nswiftlint\nelse\necho \"warning: SwiftLint not installed, download from https://github.com/realm/SwiftLint\"\nfi";
shellScript = "if which swiftlint >/dev/null; then\nswiftlint\nelse\necho \"warning: SwiftLint not installed, download from https://github.com/realm/SwiftLint\"\nfi\n";
};
/* End PBXShellScriptBuildPhase section */

Expand Down Expand Up @@ -381,7 +381,11 @@
isa = XCBuildConfiguration;
buildSettings = {
INFOPLIST_FILE = "Shari-DemoUITests/Info.plist";
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
"@loader_path/Frameworks",
);
PRODUCT_BUNDLE_IDENTIFIER = "net.nakajijapan.Shari-DemoUITests";
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_SWIFT3_OBJC_INFERENCE = Default;
Expand All @@ -395,7 +399,11 @@
isa = XCBuildConfiguration;
buildSettings = {
INFOPLIST_FILE = "Shari-DemoUITests/Info.plist";
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
"@loader_path/Frameworks",
);
PRODUCT_BUNDLE_IDENTIFIER = "net.nakajijapan.Shari-DemoUITests";
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_SWIFT3_OBJC_INFERENCE = Default;
Expand Down Expand Up @@ -428,6 +436,7 @@
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES;
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
CLANG_WARN_STRICT_PROTOTYPES = YES;
CLANG_WARN_SUSPICIOUS_MOVE = YES;
Expand All @@ -452,7 +461,7 @@
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 10.0;
IPHONEOS_DEPLOYMENT_TARGET = 13.0;
MTL_ENABLE_DEBUG_INFO = YES;
ONLY_ACTIVE_ARCH = YES;
SDKROOT = iphoneos;
Expand Down Expand Up @@ -484,6 +493,7 @@
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES;
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
CLANG_WARN_STRICT_PROTOTYPES = YES;
CLANG_WARN_SUSPICIOUS_MOVE = YES;
Expand All @@ -502,10 +512,11 @@
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 10.0;
IPHONEOS_DEPLOYMENT_TARGET = 13.0;
MTL_ENABLE_DEBUG_INFO = NO;
SDKROOT = iphoneos;
SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule";
SWIFT_COMPILATION_MODE = wholemodule;
SWIFT_OPTIMIZATION_LEVEL = "-O";
SWIFT_VERSION = 5.0;
VALIDATE_PRODUCT = YES;
};
Expand All @@ -517,8 +528,11 @@
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
DEVELOPMENT_TEAM = CNE5C4C374;
INFOPLIST_FILE = "Shari-Demo/Info.plist";
IPHONEOS_DEPLOYMENT_TARGET = 10.0;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
IPHONEOS_DEPLOYMENT_TARGET = 13.0;
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
);
PRODUCT_BUNDLE_IDENTIFIER = "net.nakajijapan.Shari-Demo";
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_VERSION = 5.0;
Expand All @@ -532,8 +546,11 @@
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
DEVELOPMENT_TEAM = CNE5C4C374;
INFOPLIST_FILE = "Shari-Demo/Info.plist";
IPHONEOS_DEPLOYMENT_TARGET = 10.0;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
IPHONEOS_DEPLOYMENT_TARGET = 13.0;
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
);
PRODUCT_BUNDLE_IDENTIFIER = "net.nakajijapan.Shari-Demo";
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_VERSION = 5.0;
Expand Down Expand Up @@ -572,6 +589,25 @@
defaultConfigurationName = Release;
};
/* End XCConfigurationList section */

/* Begin XCRemoteSwiftPackageReference section */
B012C9D526B2957F00914DF2 /* XCRemoteSwiftPackageReference "Shari" */ = {
isa = XCRemoteSwiftPackageReference;
repositoryURL = "git@github.com:nakajijapan/Shari.git";
requirement = {
branch = master;
kind = branch;
};
};
/* End XCRemoteSwiftPackageReference section */

/* Begin XCSwiftPackageProductDependency section */
B012C9D626B2957F00914DF2 /* Shari */ = {
isa = XCSwiftPackageProductDependency;
package = B012C9D526B2957F00914DF2 /* XCRemoteSwiftPackageReference "Shari" */;
productName = Shari;
};
/* End XCSwiftPackageProductDependency section */
};
rootObject = DC9E67F21C3005070095C3AB /* Project object */;
}
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1030"
LastUpgradeVersion = "1250"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
Expand Down
4 changes: 0 additions & 4 deletions Shari-DemoUITests/NavigationControllerUITests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -41,9 +41,5 @@ class NavigationControllerUITests: XCTestCase {
app.tables.staticTexts["Detail View Controller"].tap()
app.buttons["Button1"].tap()
app.otherElements["ShariOverlayView"].tap()



}

}
16 changes: 9 additions & 7 deletions Shari.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,7 @@
isa = PBXProject;
attributes = {
LastSwiftUpdateCheck = 0810;
LastUpgradeCheck = 1000;
LastUpgradeCheck = 1250;
ORGANIZATIONNAME = CocoaPods;
TargetAttributes = {
DC4D0AB61DD726C900366D6C = {
Expand Down Expand Up @@ -322,6 +322,7 @@
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES;
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
CLANG_WARN_STRICT_PROTOTYPES = YES;
CLANG_WARN_SUSPICIOUS_MOVE = YES;
Expand All @@ -347,7 +348,7 @@
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 10.0;
IPHONEOS_DEPLOYMENT_TARGET = 13.0;
MTL_ENABLE_DEBUG_INFO = YES;
ONLY_ACTIVE_ARCH = YES;
SDKROOT = iphoneos;
Expand Down Expand Up @@ -378,6 +379,7 @@
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES;
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
CLANG_WARN_STRICT_PROTOTYPES = YES;
CLANG_WARN_SUSPICIOUS_MOVE = YES;
Expand All @@ -396,7 +398,7 @@
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 10.0;
IPHONEOS_DEPLOYMENT_TARGET = 13.0;
MTL_ENABLE_DEBUG_INFO = NO;
SDKROOT = iphoneos;
SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule";
Expand All @@ -414,7 +416,7 @@
DEBUG_INFORMATION_FORMAT = dwarf;
DEVELOPMENT_TEAM = CNE5C4C374;
INFOPLIST_FILE = ShariTests/Info.plist;
IPHONEOS_DEPLOYMENT_TARGET = 10.1;
IPHONEOS_DEPLOYMENT_TARGET = 13.0;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
PRODUCT_BUNDLE_IDENTIFIER = com.pepabo.minne.ShariTests;
PRODUCT_NAME = "$(TARGET_NAME)";
Expand All @@ -432,7 +434,7 @@
CLANG_WARN_SUSPICIOUS_MOVES = YES;
DEVELOPMENT_TEAM = CNE5C4C374;
INFOPLIST_FILE = ShariTests/Info.plist;
IPHONEOS_DEPLOYMENT_TARGET = 10.1;
IPHONEOS_DEPLOYMENT_TARGET = 13.0;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
PRODUCT_BUNDLE_IDENTIFIER = com.pepabo.minne.ShariTests;
PRODUCT_NAME = "$(TARGET_NAME)";
Expand All @@ -454,7 +456,7 @@
DYLIB_INSTALL_NAME_BASE = "@rpath";
INFOPLIST_FILE = Shari/Info.plist;
INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks";
IPHONEOS_DEPLOYMENT_TARGET = 10.0;
IPHONEOS_DEPLOYMENT_TARGET = 13.0;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
PRODUCT_BUNDLE_IDENTIFIER = net.nakajijapan.Shari;
PRODUCT_NAME = "$(TARGET_NAME)";
Expand All @@ -478,7 +480,7 @@
DYLIB_INSTALL_NAME_BASE = "@rpath";
INFOPLIST_FILE = Shari/Info.plist;
INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks";
IPHONEOS_DEPLOYMENT_TARGET = 10.0;
IPHONEOS_DEPLOYMENT_TARGET = 13.0;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
PRODUCT_BUNDLE_IDENTIFIER = net.nakajijapan.Shari;
PRODUCT_NAME = "$(TARGET_NAME)";
Expand Down
24 changes: 10 additions & 14 deletions Shari.xcodeproj/xcshareddata/xcschemes/Shari.xcscheme
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1030"
LastUpgradeVersion = "1250"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
Expand All @@ -27,6 +27,15 @@
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES">
<MacroExpansion>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "DC9E67C01C2FDC020095C3AB"
BuildableName = "Shari.framework"
BlueprintName = "Shari"
ReferencedContainer = "container:Shari.xcodeproj">
</BuildableReference>
</MacroExpansion>
<Testables>
<TestableReference
skipped = "NO">
Expand All @@ -39,17 +48,6 @@
</BuildableReference>
</TestableReference>
</Testables>
<MacroExpansion>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "DC9E67C01C2FDC020095C3AB"
BuildableName = "Shari.framework"
BlueprintName = "Shari"
ReferencedContainer = "container:Shari.xcodeproj">
</BuildableReference>
</MacroExpansion>
<AdditionalOptions>
</AdditionalOptions>
</TestAction>
<LaunchAction
buildConfiguration = "Debug"
Expand All @@ -70,8 +68,6 @@
ReferencedContainer = "container:Shari.xcodeproj">
</BuildableReference>
</MacroExpansion>
<AdditionalOptions>
</AdditionalOptions>
</LaunchAction>
<ProfileAction
buildConfiguration = "Release"
Expand Down
Loading

0 comments on commit fb98039

Please sign in to comment.