// swift-tools-version:5.7 #if canImport(PackageDescription) import PackageDescription let package = Package( name: "LeadKit", platforms: [ .iOS(.v12) ], products: [ // MARK: - Application .library(name: "TIApplication", targets: ["TIApplication"]), // MARK: - UIKit .library(name: "TIUIKitCore", targets: ["TIUIKitCore"]), .library(name: "TIUIElements", targets: ["TIUIElements"]), .library(name: "TIWebView", targets: ["TIWebView"]), .library(name: "TIBottomSheet", targets: ["TIBottomSheet"]), // 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://git.svc.touchin.ru/TouchInstinct/TableKit.git", .upToNextMinor(from: "2.12.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")), .package(url: "https://git.svc.touchin.ru/TouchInstinct/PanModal", .upToNextMinor(from: "1.3.0")) ], targets: [ // MARK: - Application architecture .target(name: "TIApplication", dependencies: ["TILogging", "TIFoundationUtils", "KeychainAccess"], path: "TIApplication/Sources", plugins: [.plugin(name: "TISwiftLintPlugin")]), // MARK: - UIKit .target(name: "TIUIKitCore", dependencies: ["TISwiftUtils"], path: "TIUIKitCore/Sources"), .target(name: "TIUIElements", dependencies: ["TIUIKitCore", "TILogging"], path: "TIUIElements/Sources", exclude: ["../TIUIElements.app"], plugins: [.plugin(name: "TISwiftLintPlugin")]), .target(name: "TIWebView", dependencies: ["TIUIKitCore", "TISwiftUtils"], path: "TIWebView/Sources"), .target(name: "TIBottomSheet", dependencies: ["PanModal", "TIUIElements", "TIUIKitCore", "TISwiftUtils"], path: "TIBottomSheet/Sources", exclude: ["../TIBottomSheet.app"], plugins: [.plugin(name: "TISwiftLintPlugin")]), // 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"], resources: [ .copy("PrivacyInfo.xcprivacy"), ], 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", "Moya"], path: "TIMoyaNetworking/Sources", plugins: [.plugin(name: "TISwiftLintPlugin")]), .target(name: "TINetworkingCache", dependencies: ["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: ["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