From 10af46ce1459c719f7a2fdd915d4b9790a5a2102 Mon Sep 17 00:00:00 2001 From: "Hindrik Bruinsma (Cloud Cosmonaut)" Date: Sun, 11 Apr 2021 19:24:08 +0200 Subject: [PATCH] Add Action to verify PR --- .github/workflows/check-pr.yml | 55 ++++++++++++++++++++++++++++++++++ RFISO8601DateTime.podspec | 2 +- 2 files changed, 56 insertions(+), 1 deletion(-) create mode 100644 .github/workflows/check-pr.yml diff --git a/.github/workflows/check-pr.yml b/.github/workflows/check-pr.yml new file mode 100644 index 0000000..dd68fc0 --- /dev/null +++ b/.github/workflows/check-pr.yml @@ -0,0 +1,55 @@ +name: Check PR + +on: + pull_request: + branches: [ main ] + +env: + PROJECT_FILE: RFISO8601DateTime.xcodeproj + PROJECT_SCHEME: RFISO8601DateTimeTests + PODSPEC_FILE: RFISO8601DateTime.podspec + +jobs: + build: + + runs-on: macos-latest + + strategy: + matrix: + xcode: + - destination: platform=iOS Simulator,OS=latest,name=iPhone 11 + version : latest-stable + # - destination: platform=iOS Simulator,OS=14.4,name=iPhone 11 + # version: 12.4 + # - destination: platform=iOS Simulator,OS=13.7,name=iPhone 11 + # version: 11.7 + # - destination: platform=iOS Simulator,OS=12.4,name=iPhone 7 + # version: 10.3 + + steps: + - uses: actions/checkout@v2 + with: + ref: ${{ github.head_ref }} + - uses: ruby/setup-ruby@v1 + with: + bundler-cache: true + - uses: maxim-lobanov/setup-xcode@v1 + with: + xcode-version: ${{ matrix.xcode.version }} + + - name: Xcode Test + uses: devbotsxyz/xcode-test@v1.1.0 + with: + project: ${{ env.PROJECT_FILE }} + scheme: ${{ env.PROJECT_SCHEME }} + configuration: Debug + destination: ${{ matrix.xcode.destination }} + + - uses: codecov/codecov-action@v1 + name: Determine code coverage with CodeCov + + - name: Sed new version in Podspec + run: sed -i "" -e 's||1.1.1|g' ${{ env.PODSPEC_FILE }} + + - name: Perform Cocoapod lib lint validation + run: bundle exec pod lib lint --quick --allow-warnings diff --git a/RFISO8601DateTime.podspec b/RFISO8601DateTime.podspec index 2a38513..70d0e30 100644 --- a/RFISO8601DateTime.podspec +++ b/RFISO8601DateTime.podspec @@ -8,7 +8,7 @@ Pod::Spec.new do |s| s.name = "RFISO8601DateTime" - s.version = "3.0.3" + s.version = "" s.summary = "A library to easily use ISO8601 date and time." s.swift_version = "5.0" s.description = <<-DESC