diff --git a/.github/fixed_podspecs/Dwifft.podspec b/.github/fixed_podspecs/Dwifft.podspec new file mode 100644 index 0000000..26df1a6 --- /dev/null +++ b/.github/fixed_podspecs/Dwifft.podspec @@ -0,0 +1,20 @@ +Pod::Spec.new do |s| + s.name = 'Dwifft' + s.version = '0.9' + s.license = 'MIT' + s.summary = 'Swift Diff' + s.homepage = 'https://github.com/jflinter/Dwifft' + s.social_media_url = 'http://twitter.com/jflinter' + s.author = 'Jack Flintermann' + s.source = { git: 'https://github.com/jflinter/Dwifft.git', tag: s.version } + + s.swift_version = '5.0' + + s.ios.deployment_target = '12.0' + s.tvos.deployment_target = '12.0' + s.osx.deployment_target = '10.13' + + s.source_files = 'Dwifft/*.swift' + + s.requires_arc = true +end diff --git a/.github/fixed_podspecs/SwiftyJSON.podspec b/.github/fixed_podspecs/SwiftyJSON.podspec new file mode 100644 index 0000000..0de01cd --- /dev/null +++ b/.github/fixed_podspecs/SwiftyJSON.podspec @@ -0,0 +1,17 @@ +Pod::Spec.new do |s| + s.name = "SwiftyJSON" + s.version = "5.0.1" + s.summary = "SwiftyJSON makes it easy to deal with JSON data in Swift" + s.homepage = "https://github.com/SwiftyJSON/SwiftyJSON" + s.license = { :type => "MIT" } + s.authors = { "lingoer" => "lingoerer@gmail.com", "tangplin" => "tangplin@gmail.com" } + + s.requires_arc = true + s.swift_version = "5.0" + s.osx.deployment_target = "10.13" + s.ios.deployment_target = "12.0" + s.watchos.deployment_target = "4.0" + s.tvos.deployment_target = "12.0" + s.source = { :git => "https://github.com/SwiftyJSON/SwiftyJSON.git", :tag => s.version } + s.source_files = "Source/SwiftyJSON/*.swift" +end diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000..080f749 --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,41 @@ +name: ci +on: + pull_request: + + workflow_dispatch: + + push: + branches: + - master + +jobs: + run_pod_tests: + name: Run pod tests + runs-on: macos-latest + steps: + - name: Checkout repo + uses: actions/checkout@v4 + + - name: Setup Ruby + uses: ruby/setup-ruby@v1 + with: + bundler-cache: true + + - name: Define validation directory + id: define_validation_dir + run: echo "path=${{ runner.temp }}/validation_${{ github.run_number }}_${{ github.run_attempt }}" >> $GITHUB_OUTPUT + + - name: Run pod unit tests + run: | + bundle exec pod lib lint \ + --allow-warnings \ + --external-podspecs=".github/fixed_podspecs/**/*.podspec" \ + --validation-dir="${{ steps.define_validation_dir.outputs.path }}" \ + --no-clean + + - name: Upload test artifacts + if: ${{ failure() }} + uses: actions/upload-artifact@v3 + with: + name: test_artifacts + path: ${{ steps.define_validation_dir.outputs.path }}