From 3b8a8653a8f60ff181bb0076a18f70704dcc80a1 Mon Sep 17 00:00:00 2001 From: Luiz Rodrigo Martins Barbosa Date: Mon, 8 Jul 2019 23:33:52 +0200 Subject: [PATCH] Split products and rename them --- CombineRex.podspec | 27 +++++++++++++++++++++ Makefile | 2 +- Package.swift | 13 +++++----- ReactiveSwiftRex.podspec | 28 ++++++++++++++++++++++ RxSwiftRex.podspec | 28 ++++++++++++++++++++++ SwiftRex.podspec | 52 ++++++---------------------------------- 6 files changed, 97 insertions(+), 53 deletions(-) create mode 100644 CombineRex.podspec create mode 100644 ReactiveSwiftRex.podspec create mode 100644 RxSwiftRex.podspec diff --git a/CombineRex.podspec b/CombineRex.podspec new file mode 100644 index 00000000..e258eb89 --- /dev/null +++ b/CombineRex.podspec @@ -0,0 +1,27 @@ +Pod::Spec.new do |s| + s.name = 'CombineRex' + s.version = '0.5.0' + s.summary = 'SwiftRex is a Redux implementation on top of Combine, RxSwift or ReactiveSwift. This package implements SwiftRex using RxSwift.' + s.description = <<-DESC + SwiftRex is a framework that combines event-sourcing pattern and reactive programming (Combine, RxSwift or ReactiveSwift), providing a central state Store of which your ViewControllers or SwiftUI Views can observe and react to, as well as dispatching events coming from the user interaction. + This pattern is also known as 'Unidirectional Dataflow' or 'Redux'. + DESC + s.homepage = 'https://github.com/SwiftRex/SwiftRex' + s.license = { :type => 'Apache 2.0', :file => 'LICENSE' } + s.author = { 'Luiz Barbosa' => 'swiftrex@developercity.de' } + s.source = { :git => 'https://github.com/swiftrex/SwiftRex.git', + :tag => "v#{s.version}" } + + s.requires_arc = true + + s.frameworks = 'Foundation', 'Combine' + + s.ios.deployment_target = '13.0' + s.osx.deployment_target = '10.15' + s.watchos.deployment_target = '6.0' + s.tvos.deployment_target = '13.0' + s.swift_version = '5.1' + + s.source_files = "Sources/Combine/" + s.dependency 'SwiftRex', "#{s.version}" +end diff --git a/Makefile b/Makefile index 00e11a27..4fe786ab 100644 --- a/Makefile +++ b/Makefile @@ -5,7 +5,7 @@ set-version: $(error Missing new version number. Please use `make set-version TO=1.2.3`) else set-version: - sed -i .bkp -E "s/(s\.version.*=.*)'.*'/\1'${TO}'/" SwiftRex.podspec + sed -i .bkp -E "s/(s\.version.*=.*)'.*'/\1'${TO}'/" *.podspec sed -i .bkp -E "s/(CURRENT_PROJECT_VERSION.*= ).*/\1${TO}/" Configuration/SwiftRex-Common.xcconfig endif diff --git a/Package.swift b/Package.swift index e6c72497..b143ad05 100644 --- a/Package.swift +++ b/Package.swift @@ -4,10 +4,9 @@ import PackageDescription let package = Package( name: "SwiftRex", products: [ - .library(name: "SwiftRex", targets: ["SwiftRex"]), - .library(name: "SwiftRexForCombine", targets: ["SwiftRexForCombine"]), - .library(name: "SwiftRexForRac", targets: ["SwiftRexForRac"]), - .library(name: "SwiftRexForRx", targets: ["SwiftRexForRx"]) + .library(name: "CombineRex", targets: ["SwiftRex", "CombineRex"]), + .library(name: "ReactiveSwiftRex", targets: ["SwiftRex", "ReactiveSwiftRex"]), + .library(name: "RxSwiftRex", targets: ["SwiftRex", "RxSwiftRex"]) ], dependencies: [ .package(url: "https://github.com/ReactiveCocoa/ReactiveSwift.git", .exact("6.0.0")), @@ -15,9 +14,9 @@ let package = Package( ], targets: [ .target(name: "SwiftRex", dependencies: [], path: "Sources/Common"), - .target(name: "SwiftRexForCombine", dependencies: ["SwiftRex"], path: "Sources/Combine"), - .target(name: "SwiftRexForRac", dependencies: ["SwiftRex", "ReactiveSwift"], path: "Sources/ReactiveSwift"), - .target(name: "SwiftRexForRx", dependencies: ["SwiftRex", "RxSwift"], path: "Sources/RxSwift") + .target(name: "CombineRex", dependencies: ["SwiftRex"], path: "Sources/Combine"), + .target(name: "ReactiveSwiftRex", dependencies: ["SwiftRex", "ReactiveSwift"], path: "Sources/ReactiveSwift"), + .target(name: "RxSwiftRex", dependencies: ["SwiftRex", "RxSwift"], path: "Sources/RxSwift") ], swiftLanguageVersions: [.v5] ) diff --git a/ReactiveSwiftRex.podspec b/ReactiveSwiftRex.podspec new file mode 100644 index 00000000..55bdf8d1 --- /dev/null +++ b/ReactiveSwiftRex.podspec @@ -0,0 +1,28 @@ +Pod::Spec.new do |s| + s.name = 'ReactiveSwiftRex' + s.version = '0.5.0' + s.summary = 'SwiftRex is a Redux implementation on top of Combine, RxSwift or ReactiveSwift. This package implements SwiftRex using ReactiveSwift.' + s.description = <<-DESC + SwiftRex is a framework that combines event-sourcing pattern and reactive programming (Combine, RxSwift or ReactiveSwift), providing a central state Store of which your ViewControllers or SwiftUI Views can observe and react to, as well as dispatching events coming from the user interaction. + This pattern is also known as 'Unidirectional Dataflow' or 'Redux'. + DESC + s.homepage = 'https://github.com/SwiftRex/SwiftRex' + s.license = { :type => 'Apache 2.0', :file => 'LICENSE' } + s.author = { 'Luiz Barbosa' => 'swiftrex@developercity.de' } + s.source = { :git => 'https://github.com/swiftrex/SwiftRex.git', + :tag => "v#{s.version}" } + + s.requires_arc = true + + s.frameworks = 'Foundation' + + s.ios.deployment_target = '8.0' + s.osx.deployment_target = '10.10' + s.watchos.deployment_target = '3.0' + s.tvos.deployment_target = '9.0' + s.swift_version = '5.0' + + s.source_files = "Sources/ReactiveSwift/" + s.dependency 'SwiftRex', "#{s.version}" + s.dependency 'ReactiveSwift', '~> 6' +end diff --git a/RxSwiftRex.podspec b/RxSwiftRex.podspec new file mode 100644 index 00000000..95f2a573 --- /dev/null +++ b/RxSwiftRex.podspec @@ -0,0 +1,28 @@ +Pod::Spec.new do |s| + s.name = 'RxSwiftRex' + s.version = '0.5.0' + s.summary = 'SwiftRex is a Redux implementation on top of Combine, RxSwift or ReactiveSwift. This package implements SwiftRex using RxSwift.' + s.description = <<-DESC + SwiftRex is a framework that combines event-sourcing pattern and reactive programming (Combine, RxSwift or ReactiveSwift), providing a central state Store of which your ViewControllers or SwiftUI Views can observe and react to, as well as dispatching events coming from the user interaction. + This pattern is also known as 'Unidirectional Dataflow' or 'Redux'. + DESC + s.homepage = 'https://github.com/SwiftRex/SwiftRex' + s.license = { :type => 'Apache 2.0', :file => 'LICENSE' } + s.author = { 'Luiz Barbosa' => 'swiftrex@developercity.de' } + s.source = { :git => 'https://github.com/swiftrex/SwiftRex.git', + :tag => "v#{s.version}" } + + s.requires_arc = true + + s.frameworks = 'Foundation' + + s.ios.deployment_target = '8.0' + s.osx.deployment_target = '10.10' + s.watchos.deployment_target = '3.0' + s.tvos.deployment_target = '9.0' + s.swift_version = '5.0' + + s.source_files = "Sources/RxSwift/" + s.dependency 'SwiftRex', "#{s.version}" + s.dependency 'RxSwift', '~> 5' +end diff --git a/SwiftRex.podspec b/SwiftRex.podspec index 188037bf..680fa5e3 100644 --- a/SwiftRex.podspec +++ b/SwiftRex.podspec @@ -15,51 +15,13 @@ Pod::Spec.new do |s| s.requires_arc = true s.frameworks = 'Foundation' - s.default_subspec = 'Core' - s.subspec "Core" do |ss| - ss.ios.deployment_target = '8.0' - ss.osx.deployment_target = '10.10' - ss.watchos.deployment_target = '3.0' - ss.tvos.deployment_target = '9.0' - ss.swift_version = '5.0' + s.ios.deployment_target = '8.0' + s.osx.deployment_target = '10.10' + s.watchos.deployment_target = '3.0' + s.tvos.deployment_target = '9.0' + s.swift_version = '5.0' - ss.source_files = "Sources/Common/" - ss.framework = "Foundation" - end - - s.subspec "UsingCombine" do |ss| - ss.ios.deployment_target = '13.0' - ss.osx.deployment_target = '10.15' - ss.watchos.deployment_target = '6.0' - ss.tvos.deployment_target = '13.0' - ss.swift_version = '5.1' - - ss.source_files = "Sources/Combine/" - ss.dependency "SwiftRex/Core" - end - - s.subspec "UsingRxSwift" do |ss| - ss.ios.deployment_target = '8.0' - ss.osx.deployment_target = '10.10' - ss.watchos.deployment_target = '3.0' - ss.tvos.deployment_target = '9.0' - ss.swift_version = '5.0' - - ss.source_files = "Sources/RxSwift/" - ss.dependency "SwiftRex/Core" - ss.dependency 'RxSwift' - end - - s.subspec "UsingReactiveSwift" do |ss| - ss.ios.deployment_target = '8.0' - ss.osx.deployment_target = '10.10' - ss.watchos.deployment_target = '3.0' - ss.tvos.deployment_target = '9.0' - ss.swift_version = '5.0' - - ss.source_files = "Sources/ReactiveSwift/" - ss.dependency "SwiftRex/Core" - ss.dependency 'ReactiveSwift' - end + s.source_files = "Sources/Common/" + s.framework = "Foundation" end