170 lines
7.0 KiB
Swift
170 lines
7.0 KiB
Swift
// swift-tools-version:5.7
|
|
|
|
#if canImport(PackageDescription)
|
|
|
|
import PackageDescription
|
|
|
|
let package = Package(
|
|
name: "LeadKit",
|
|
platforms: [
|
|
.iOS(.v11)
|
|
],
|
|
products: [
|
|
|
|
// MARK: - UIKit
|
|
.library(name: "TIUIKitCore", targets: ["TIUIKitCore"]),
|
|
.library(name: "TIUIElements", targets: ["TIUIElements"]),
|
|
.library(name: "TIWebView", targets: ["TIWebView"]),
|
|
|
|
// MARK: - SwiftUI
|
|
.library(name: "TISwiftUICore", targets: ["TISwiftUICore"]),
|
|
|
|
// MARK: - Utils
|
|
.library(name: "TISwiftUtils", targets: ["TISwiftUtils"]),
|
|
.library(name: "TIFoundationUtils", targets: ["TIFoundationUtils"]),
|
|
.library(name: "TICoreGraphicsUtils", targets: ["TICoreGraphicsUtils"]),
|
|
.library(name: "TIKeychainUtils", targets: ["TIKeychainUtils"]),
|
|
.library(name: "TITableKitUtils", targets: ["TITableKitUtils"]),
|
|
.library(name: "TIDeeplink", targets: ["TIDeeplink"]),
|
|
.library(name: "TIDeveloperUtils", targets: ["TIDeveloperUtils"]),
|
|
|
|
// MARK: - Networking
|
|
|
|
.library(name: "TINetworking", targets: ["TINetworking"]),
|
|
.library(name: "TIMoyaNetworking", targets: ["TIMoyaNetworking"]),
|
|
.library(name: "TINetworkingCache", targets: ["TINetworkingCache"]),
|
|
|
|
// MARK: - Maps
|
|
|
|
.library(name: "TIMapUtils", targets: ["TIMapUtils"]),
|
|
.library(name: "TIAppleMapUtils", targets: ["TIAppleMapUtils"]),
|
|
|
|
// MARK: - Elements
|
|
.library(name: "OTPSwiftView", targets: ["OTPSwiftView"]),
|
|
.library(name: "TITransitions", targets: ["TITransitions"]),
|
|
.library(name: "TIPagination", targets: ["TIPagination"]),
|
|
.library(name: "TIAuth", targets: ["TIAuth"]),
|
|
.library(name: "TIEcommerce", targets: ["TIEcommerce"]),
|
|
.library(name: "TITextProcessing", targets: ["TITextProcessing"])
|
|
],
|
|
dependencies: [
|
|
.package(url: "https://github.com/maxsokolov/TableKit.git", .upToNextMajor(from: "2.11.0")),
|
|
.package(url: "https://github.com/kishikawakatsumi/KeychainAccess.git", .upToNextMajor(from: "4.2.2")),
|
|
.package(url: "https://github.com/petropavel13/Cursors", .upToNextMajor(from: "0.5.1")),
|
|
.package(url: "https://github.com/Alamofire/Alamofire.git", .upToNextMajor(from: "5.4.0")),
|
|
.package(url: "https://github.com/Moya/Moya.git", .upToNextMajor(from: "15.0.0")),
|
|
.package(url: "https://github.com/hyperoslo/Cache.git", .upToNextMajor(from: "6.0.0")),
|
|
.package(url: "https://github.com/antlr/antlr4", .upToNextMinor(from: "4.10.1"))
|
|
],
|
|
targets: [
|
|
|
|
// MARK: - UIKit
|
|
.target(name: "TIUIKitCore", dependencies: ["TISwiftUtils"], path: "TIUIKitCore/Sources"),
|
|
|
|
.target(name: "TIUIElements",
|
|
dependencies: ["TIUIKitCore", "TISwiftUtils"],
|
|
path: "TIUIElements/Sources",
|
|
exclude: ["../TIUIElements.app"],
|
|
plugins: [.plugin(name: "TISwiftLintPlugin")]),
|
|
|
|
.target(name: "TIWebView", dependencies: ["TIUIKitCore", "TISwiftUtils"], path: "TIWebView/Sources"),
|
|
|
|
// MARK: - SwiftUI
|
|
.target(name: "TISwiftUICore", dependencies: ["TIUIKitCore", "TISwiftUtils"], path: "TISwiftUICore/Sources"),
|
|
|
|
// MARK: - Utils
|
|
|
|
.target(name: "TISwiftUtils",
|
|
path: "TISwiftUtils/Sources",
|
|
plugins: [.plugin(name: "TISwiftLintPlugin")]),
|
|
|
|
.target(name: "TIFoundationUtils",
|
|
dependencies: ["TISwiftUtils", "TILogging"],
|
|
path: "TIFoundationUtils",
|
|
exclude: ["TIFoundationUtils.app"],
|
|
plugins: [.plugin(name: "TISwiftLintPlugin")]),
|
|
|
|
.target(name: "TICoreGraphicsUtils",
|
|
dependencies: [],
|
|
path: "TICoreGraphicsUtils/Sources",
|
|
exclude: ["../TICoreGraphicsUtils.app"],
|
|
plugins: [.plugin(name: "TISwiftLintPlugin")]),
|
|
|
|
.target(name: "TIKeychainUtils",
|
|
dependencies: ["TIFoundationUtils", "KeychainAccess"],
|
|
path: "TIKeychainUtils/Sources",
|
|
exclude: ["../TIKeychainUtils.app"],
|
|
plugins: [.plugin(name: "TISwiftLintPlugin")]),
|
|
|
|
.target(name: "TITableKitUtils", dependencies: ["TIUIElements", "TableKit"], path: "TITableKitUtils/Sources"),
|
|
.target(name: "TIDeeplink", dependencies: ["TIFoundationUtils"], path: "TIDeeplink", exclude: ["TIDeeplink.app"]),
|
|
.target(name: "TIDeveloperUtils", dependencies: ["TISwiftUtils", "TIUIKitCore", "TIUIElements"], path: "TIDeveloperUtils/Sources"),
|
|
.target(name: "TILogging", path: "TILogging/Sources", plugins: ["TISwiftLintPlugin"]),
|
|
|
|
// MARK: - Networking
|
|
|
|
.target(name: "TINetworking",
|
|
dependencies: ["TIFoundationUtils", "Alamofire", "TILogging"],
|
|
path: "TINetworking/Sources",
|
|
plugins: [.plugin(name: "TISwiftLintPlugin")]),
|
|
|
|
.target(name: "TIMoyaNetworking",
|
|
dependencies: ["TINetworking", "TIFoundationUtils", "Moya"],
|
|
path: "TIMoyaNetworking/Sources",
|
|
plugins: [.plugin(name: "TISwiftLintPlugin")]),
|
|
|
|
.target(name: "TINetworkingCache",
|
|
dependencies: ["TIFoundationUtils", "TINetworking", "Cache"],
|
|
path: "TINetworkingCache/Sources",
|
|
plugins: [.plugin(name: "TISwiftLintPlugin")]),
|
|
|
|
// MARK: - Maps
|
|
|
|
.target(name: "TIMapUtils",
|
|
dependencies: ["TILogging", "TICoreGraphicsUtils"],
|
|
path: "TIMapUtils/Sources",
|
|
plugins: [.plugin(name: "TISwiftLintPlugin")]),
|
|
|
|
.target(name: "TIAppleMapUtils",
|
|
dependencies: ["TIMapUtils"],
|
|
path: "TIAppleMapUtils/Sources",
|
|
plugins: [.plugin(name: "TISwiftLintPlugin")]),
|
|
|
|
// MARK: - Elements
|
|
.target(name: "OTPSwiftView", dependencies: ["TIUIElements"], path: "OTPSwiftView/Sources"),
|
|
.target(name: "TITransitions", path: "TITransitions/Sources"),
|
|
.target(name: "TIPagination", dependencies: ["Cursors", "TISwiftUtils"], path: "TIPagination/Sources"),
|
|
.target(name: "TIAuth", dependencies: ["TIFoundationUtils", "TIUIKitCore", "TIKeychainUtils"], path: "TIAuth/Sources"),
|
|
.target(name: "TIEcommerce", dependencies: ["TIFoundationUtils", "TISwiftUtils", "TINetworking", "TIUIKitCore", "TIUIElements"], path: "TIEcommerce/Sources"),
|
|
.target(name: "TITextProcessing",
|
|
dependencies: [.product(name: "Antlr4", package: "antlr4")],
|
|
path: "TITextProcessing/Sources",
|
|
exclude: ["../TITextProcessing.app"]),
|
|
|
|
.binaryTarget(name: "SwiftLintBinary",
|
|
url: "https://github.com/realm/SwiftLint/releases/download/0.52.2/SwiftLintBinary-macos.artifactbundle.zip",
|
|
checksum: "89651e1c87fb62faf076ef785a5b1af7f43570b2b74c6773526e0d5114e0578e"),
|
|
|
|
.plugin(name: "TISwiftLintPlugin",
|
|
capability: .buildTool(),
|
|
dependencies: ["SwiftLintBinary"]),
|
|
|
|
// MARK: - Tests
|
|
|
|
.testTarget(
|
|
name: "TITimerTests",
|
|
dependencies: ["TIFoundationUtils"],
|
|
path: "Tests/TITimerTests"),
|
|
.testTarget(
|
|
name: "TITextProcessingTests",
|
|
dependencies: ["TITextProcessing"],
|
|
path: "Tests/TITextProcessingTests"),
|
|
.testTarget(
|
|
name: "TIFoundationUtilsTests",
|
|
dependencies: ["TIFoundationUtils", "TISwiftUtils", "TILogging"],
|
|
path: "Tests/TIFoundationUtilsTests")
|
|
]
|
|
)
|
|
|
|
#endif
|