Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Switch to GitHub Actions #415

Merged
merged 2 commits into from
Feb 28, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
67 changes: 67 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,67 @@
name: CI

on:
pull_request:
push:
branches:
- main
- master

jobs:
test-on-macos:
name: Test on macOS
runs-on: macOS-latest
strategy:
matrix:
xcode: [11.4, 12.3]
steps:
- uses: actions/checkout@v2

- name: Select Xcode
run: |
xcodebuild -version
ls -nt /Applications/ | grep "Xcode*"
sudo xcode-select -switch /Applications/Xcode_${{ matrix.xcode }}.app
xcodebuild -version

- name: Install danger-js
run: brew install danger/tap/danger-js

- run: swift test

- run: swift run danger-swift ci --verbose
if: ${{ github.event_name == 'pull_request' }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

test-on-linux:
name: Test on Linux
runs-on: ubuntu-latest
strategy:
matrix:
swift: [5.2.4, 5.3.3]
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v2

- name: Install danger-js
run: |
yarn global add danger
echo `yarn global bin` >> $GITHUB_PATH

- run: echo ${{ matrix.swift }} > .swift-version

- uses: YOCKOW/Action-setup-swift@v1

# - name: Install swiftenv
# run: |
# echo ${{ matrix.swift }} > .swift-version
# eval "$(curl -sL https://swiftenv.fuller.li/install.sh)"
# swift --version

- run: swift test

- run: swift run danger-swift ci --verbose
if: ${{ github.event_name == 'pull_request' }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
# gitignore contributors: remember to update Global/Xcode.gitignore, Objective-C.gitignore & Swift.gitignore

## Build generated
.derivedData/
build/
DerivedData/
/*.tar.gz
Expand Down
129 changes: 0 additions & 129 deletions .travis.yml

This file was deleted.