Update README.md #76
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
# This workflow will build a Swift project | |
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-swift | |
name: Swift | |
on: | |
push: | |
branches: [ "develop" ] | |
pull_request: | |
branches: [ "develop" ] | |
jobs: | |
build: | |
runs-on: macos-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set Xcode version | |
run: sudo xcode-select -switch /Applications/Xcode_16.app | |
- name: Resolve Dependencies | |
run: xcodebuild -resolvePackageDependencies | |
working-directory: ./Smeem-iOS | |
- name: Create Debug.xcconfig | |
run: echo "${{ secrets.DEBUG_CONFIG }}" > ./Smeem-iOS/Debug.xcconfig | |
- name: Build | |
run: xcodebuild clean test -project Smeem-iOS/Smeem-iOS.xcodeproj -scheme Smeem-Dev -destination 'platform=iOS Simulator,name=iPhone 15,OS=17.2' -quiet | |
# 성공 시 Discord 알림 | |
- name: Notify Discord on success | |
if: success() | |
run: | | |
curl -H "Content-Type: application/json" \ | |
-d '{"username": "GitHub Actions", "content": "✅ Build succeeded for branch `${{ github.ref_name }}`."}' \ | |
${{ secrets.DISCORD_WEBHOOK_URL_DEV }} | |
# # 실패 시 Discord 알림 | |
- name: Notify Discord on failure | |
if: failure() | |
run: | | |
curl -H "Content-Type: application/json" \ | |
-d '{"username": "GitHub Actions", "content": "❌ Build failed for branch `${{ github.ref_name }}`. Check logs for details."}' \ | |
${{ secrets.DISCORD_WEBHOOK_URL_DEV }} |