diff --git a/.gitignore b/.gitignore index db95aaf..4ddbe73 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,4 @@ xcuserdata/ *.xcuserdata .DS_Store +.build/ \ No newline at end of file diff --git a/CodableWrapper.podspec b/CodableWrapper.podspec new file mode 100644 index 0000000..b6440e9 --- /dev/null +++ b/CodableWrapper.podspec @@ -0,0 +1,44 @@ +# +# Be sure to run `pod lib lint CodableWrapper.podspec' to ensure this is a +# valid spec before submitting. +# +# Any lines starting with a # are optional, but their use is encouraged +# To learn more about a Podspec see https://guides.cocoapods.org/syntax/podspec.html +# + +Pod::Spec.new do |s| + s.name = 'CodableWrapper' + s.version = '1.1.0' + s.summary = 'A short description of CodableWrapper.' + + s.description = <<-DESC + CodableWrapper Pod + DESC + + s.homepage = 'https://github.com/winddpan/CodableWrapper' + s.author = { 'winddpan' => 'https://github.com/winddpan' } + s.source = { :git => 'git@github.com:winddpan/CodableWrapper.git', :tag => s.version.to_s } + + s.ios.deployment_target = '13.0' + + s.source_files = 'Sources/CodableWrapper/*{.swift}' + s.preserve_paths = ["Package.swift", "Sources/CodableWrapperMacros", "Tests", "Bin"] + + s.pod_target_xcconfig = { + "OTHER_SWIFT_FLAGS" => "-Xfrontend -load-plugin-executable -Xfrontend $(PODS_BUILD_DIR)/CodableWrapper/release/CodableWrapperMacros#CodableWrapperMacros" + } + + s.user_target_xcconfig = { + "OTHER_SWIFT_FLAGS" => "-Xfrontend -load-plugin-executable -Xfrontend $(PODS_BUILD_DIR)/CodableWrapper/release/CodableWrapperMacros#CodableWrapperMacros" + } + + script = <<-SCRIPT + env -i PATH="$PATH" "$SHELL" -l -c "swift build -c release --package-path \\"$PODS_TARGET_SRCROOT\\" --build-path \\"${PODS_BUILD_DIR}/CodableWrapper\\"" + SCRIPT + + s.script_phase = { + :name => 'Build CodableWrapper macro plugin', + :script => script, + :execution_position => :before_compile + } +end diff --git a/README.md b/README.md index aecaa1c..cd1ffb8 100644 --- a/README.md +++ b/README.md @@ -2,7 +2,7 @@ | Xcode | Minimun Deployments | Version | | --------- | ------------------- | -------------------------------------------------------------- | -| Xcode15 | >= iOS13 / macOS11 | 1.0 | +| Xcode15 | >= iOS13 / macOS11 | 1.0+ | | < Xcode15 | < iOS13 / macOS11 | [0.3.3](https://github.com/winddpan/CodableWrapper/tree/0.3.3) | # About @@ -21,8 +21,8 @@ The project objective is to enhance the usage experience of the Codable protocol ## Installation -#### Cocoapods [Beta test](https://github.com/winddpan/CodableWrapper/tree/1.1.0) -``` pod 'CodableWrapper', :git => 'https://github.com/winddpan/CodableWrapper.git', :branch => '1.1.0' ``` +#### Cocoapods +``` pod 'CodableWrapper' ``` #### Swift Package Manager ``` https://github.com/winddpan/CodableWrapper ```