name: Setup macOS dependencies inputs: build-type: description: Type for the build required: true default: Debug github-token: description: GitHub token for package feed authentication required: true runs: using: composite steps: - name: Install dependencies shell: bash run: | brew update brew install ninja extra-cmake-modules temurin@17 mono autoconf libarchive - name: Set JAVA_HOME shell: bash run: | echo "JAVA_HOME=$(/usr/libexec/java_home -v 17)" >> "$GITHUB_ENV" - name: Setup vcpkg cache if: ${{ inputs.build-type == 'Debug' }} shell: bash env: USERNAME: ${{ github.repository_owner }} GITHUB_TOKEN: ${{ inputs.github-token }} FEED_URL: https://nuget.pkg.github.com/${{ github.repository_owner }}/index.json NUGET_RW: ${{ github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name == github.repository }} run: | mono `vcpkg fetch nuget | tail -n 1` \ sources add \ -Source "$FEED_URL" \ -StorePasswordInClearText \ -Name GitHubPackages \ -UserName "$USERNAME" \ -Password "$GITHUB_TOKEN" mono `vcpkg fetch nuget | tail -n 1` \ setapikey "$GITHUB_TOKEN" \ -Source "$FEED_URL" MODE=$( [ "$NUGET_RW" = "true" ] && echo "readwrite" || echo "read" ) echo "VCPKG_BINARY_SOURCES=clear;nuget,$FEED_URL,$MODE" >> "$GITHUB_ENV" - name: Setup vcpkg environment shell: bash run: | echo "VCPKG_ROOT=$VCPKG_INSTALLATION_ROOT" >> "$GITHUB_ENV"