Skip to content

Commit

Permalink
CI: Update scheduled workflow to refresh macOS dependency caches
Browse files Browse the repository at this point in the history
  • Loading branch information
PatTheMav committed Jun 15, 2023
1 parent 53215b4 commit 1f8c1f5
Showing 1 changed file with 53 additions and 0 deletions.
53 changes: 53 additions & 0 deletions .github/workflows/scheduled.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,59 @@ jobs:
--jq '.actions_caches.[] | select(.ref|test("refs/heads/master")|not) | {id, key, ref} | join(";")')"
echo '::endgroup::'
macos-build:
name: Build macOS Dependencies
runs-on: macos-13
strategy:
fail-fast: true
matrix:
target: [macos-arm64, macos-x86_64]
include:
- target: macos-arm64
config: Release
type: static
- target: macos-x86_64
config: Release
type: static
defaults:
run:
shell: zsh --no-rcs --errexit --pipefail {0}
steps:
- name: Checkout
uses: actions/checkout@v3

- name: Setup Environment
id: setup
run: |
: Setup Environment
to_remove=()
for formula (llvm gcc) {
if [[ -d /usr/local/opt/"${formula}" ]] to_remove+=(${formula})
}
if (( #to_remove )) brew uninstall --ignore-dependencies ${to_remove}
local -r date_string=$(date +"%Y-%m-%d")
print "ccacheDate=${date_string} >> $GITHUB_OUTPUT
- name: Restore Compilation Cache
id: ccache-cache
uses: actions/cache@v3
with:
path: ${{ github.workspace }}/.ccache
key: ${{ matrix.target }}-ccache-deps-${{ matrix.config }}-${{ steps.setup.outputs.ccacheDate }}
restore-keys: |
${{ matrix.target }}-ccache-deps-${{ matrix.config }}-
- name: Build macOS Dependencies
uses: ./.github/actions/build-deps
with:
target: ${{ matrix.target }}
type: ${{ matrix.type }}
config: ${{ matrix.config }}

windows-build:
name: Build Windows Dependencies
runs-on: windows-2022
Expand Down

0 comments on commit 1f8c1f5

Please sign in to comment.