name: dev-build-mac on: push: branches-ignore: - master paths: - 'src/MaaCore/**' - 'src/MaaMacGui/**' - '3rdparty/**' - 'include/**' - 'resource/**' - 'cmake/**' - CMakeLists.txt pull_request: branches: - dev paths: - 'src/MaaCore/**' - 'src/MaaMacGui/**' - '3rdparty/**' - 'include/**' - 'resource/**' - 'cmake/**' - CMakeLists.txt jobs: macos-latest: runs-on: macos-12 steps: - uses: actions/checkout@v3 with: submodules: recursive fetch-depth: 100 - name: Cache Homebrew uses: actions/cache@v3 with: path: $(brew --prefix) key: ${{ runner.os }}-homebrew-${{ hashFiles('.config/brew/Brewfile') }} - name: Install Dependencies run: | brew update --preinstall brew install ninja pkg-config range-v3 - name: Bootstrap MaaDeps env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} run: | python3 maadeps-download.py - name: Configure MaaCore run: | cmake -B build -GNinja -DBUILD_XCFRAMEWORK=ON -DCMAKE_OSX_ARCHITECTURES=x86_64 - name: Build libMaaCore run: cmake --build build - name: Build MAA working-directory: src/MaaMacGui run: xcodebuild CODE_SIGN_IDENTITY="-" DEVELOPMENT_TEAM="-" -derivedDataPath DerivedData -project MeoAsstMac.xcodeproj -scheme MAA - uses: actions/upload-artifact@v3 with: name: MAA-macos path: src/MaaMacGui/DerivedData/Build/Products/Debug