Skip to content

Commit

Permalink
update github actions
Browse files Browse the repository at this point in the history
  • Loading branch information
wendyliga committed Jan 15, 2024
1 parent fa564dc commit a768f50
Show file tree
Hide file tree
Showing 2 changed files with 73 additions and 61 deletions.
59 changes: 59 additions & 0 deletions .github/workflows/base.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
name: Base

on:
workflow_call:
inputs:
os:
description: 'The OS to run the job on'
required: true
type: string
xcode:
description: 'The Xcode version to run the job on'
required: true
type: string

jobs:

build_library:
runs-on: ${{ inputs.os }}
steps:
- uses: actions/checkout@v3
- name: Select Xcode ${{ inputs.xcode }}
run: sudo xcode-select -s /Applications/Xcode_${{ inputs.xcode }}.app
- name: Run build
run: make build-library
- name: Run benchmark
run: make benchmark

unit_test_library:
runs-on: ${{ inputs.os }}
steps:
- uses: actions/checkout@v3
- name: Select Xcode ${{ inputs.xcode }}
run: sudo xcode-select -s /Applications/Xcode_${{ inputs.xcode }}.app
- name: Run tests
run: make test-library

unit_test_example:
runs-on: ${{ inputs.os }}}
steps:
- uses: actions/checkout@v3
- name: Selext Xcode ${{ inputs.xcode }}
run: sudo xcode-select -s /Applications/Xcode_${{ inputs.xcode }}.app
- name: Run tests
run: make test-example

lint_podspec:
runs-on: ${{ inputs.os }}}
steps:
- uses: actions/checkout@v3
- name: Selext Xcode ${{ inputs.xcode }}
run: sudo xcode-select -s /Applications/Xcode_${{ inputs.xcode }}.app
- name: Install cocoapods
run: sudo gem install cocoapods
- name: Lint podspec
run: pod lib lint --allow-warnings --quick




75 changes: 14 additions & 61 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,66 +9,19 @@ on:
- '*'

jobs:
build_library:
build:
strategy:
matrix:
xcode:
- '14.3.1'
- '15.0.1'
runs-on: macos-13
steps:
- uses: actions/checkout@v3
- name: Select Xcode ${{ matrix.xcode }}
run: sudo xcode-select -s /Applications/Xcode_${{ matrix.xcode }}.app
- name: Run build
run: make build-library
- name: Run benchmark
run: make benchmark

unit_test_library:
strategy:
matrix:
xcode:
- '14.3.1'
- '15.0.1'
runs-on: macos-13
steps:
- uses: actions/checkout@v3
- name: Select Xcode ${{ matrix.xcode }}
run: sudo xcode-select -s /Applications/Xcode_${{ matrix.xcode }}.app
- name: Run tests
run: make test-library

unit_test_example:
strategy:
matrix:
xcode:
- '14.3.1'
- '15.0.1'
runs-on: macos-13
steps:
- uses: actions/checkout@v3
- name: Selext Xcode ${{ matrix.xcode }}
run: sudo xcode-select -s /Applications/Xcode_${{ matrix.xcode }}.app
- name: Run tests
run: make test-example

lint_podspec:
strategy:
matrix:
xcode:
- '14.3.1'
- '15.0.1'
runs-on: macos-13
steps:
- uses: actions/checkout@v3
- name: Selext Xcode ${{ matrix.xcode }}
run: sudo xcode-select -s /Applications/Xcode_14.1.app
- name: Install cocoapods
run: sudo gem install cocoapods
- name: Lint podspec
run: pod lib lint --allow-warnings --quick




include:
- os: macos-13
xcode: '15.0.1'
- os: macos-13
xcode: '14.3.1'
- os: macos-12
xcode: '14.3.1'
- os: macos-12
xcode: '13.4.1'
uses: ./.github/workflows/base.yml
with:
os: ${{ matrix.os }}
xcode: ${{ matrix.xcode }}

0 comments on commit a768f50

Please sign in to comment.