Skip to content
This repository has been archived by the owner on Nov 22, 2023. It is now read-only.

Cache

Cache #4149

Workflow file for this run

name: Cache
on:
push:
paths:
- .github/workflows/cache.yml
schedule:
- cron: "0 */6 * * *" # every 6 hours
concurrency:
group: cache
cancel-in-progress: true
permissions:
contents: read
jobs:
update:
if: startsWith(github.repository, 'Homebrew/')
strategy:
matrix:
runner:
- macos-11
- macos-12
- macos-13
- ubuntu-latest
runs-on: ${{ matrix.runner }}
steps:
- name: Set up Homebrew
id: set-up-homebrew
uses: Homebrew/actions/setup-homebrew@master
with:
test-bot: false
- name: Cache Homebrew Gems
id: cache
uses: actions/cache@v3
with:
path: ${{ steps.set-up-homebrew.outputs.gems-path }}
key: ${{ matrix.runner }}-rubygems-${{ steps.set-up-homebrew.outputs.gems-hash }}
restore-keys: ${{ matrix.runner }}-rubygems-
- name: Install Homebrew Gems
id: gems
run: brew install-bundler-gems
if: steps.cache.outputs.cache-hit != 'true'