CI #559
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: CI | |
on: | |
push: | |
branches: [ master ] | |
pull_request: | |
branches: [ master ] | |
workflow_dispatch: | |
concurrency: | |
group: mailosaur-swift | |
cancel-in-progress: true | |
jobs: | |
build: | |
runs-on: macos-latest | |
timeout-minutes: 10 | |
env: | |
MAILOSAUR_BASE_URL: https://mailosaur.com/ | |
MAILOSAUR_SMTP_HOST: mailosaur.net | |
MAILOSAUR_SMTP_PORT: 2525 | |
MAILOSAUR_API_KEY: ${{ secrets.MAILOSAUR_API_KEY }} | |
MAILOSAUR_SERVER: ${{ secrets.MAILOSAUR_SERVER }} | |
MAILOSAUR_VERIFIED_DOMAIN: ${{ secrets.MAILOSAUR_VERIFIED_DOMAIN }} | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Select Xcode version | |
run: sudo xcode-select -s '/Applications/Xcode_14.2.app/Contents/Developer' | |
# - name: Pod lib lint | |
# run: pod lib lint --allow-warnings | |
- name: Build project | |
run: swift build | |
- name: Run tests | |
run: swift test | |
- name: Notify on Failure | |
uses: skitionek/notify-microsoft-teams@master | |
if: ${{ failure() }} | |
with: | |
webhook_url: ${{ secrets.TEAMS_BUILDS_WEBHOOK }} | |
needs: ${{ toJson(needs) }} | |
job: ${{ toJson(job) }} | |
overwrite: "{ title: `${workflow} failed for ${repository.name}` }" |