Files
react-native/.github/actions/setup-xcode-build-cache/action.yml
T
Nicola Corti 818dd92a4a Align github/* action versions on major (#45542)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/45542

As we do have several version numbers for external actions all across the codebase,
here I'm aligning all of them to just use the majors.

I'm doing it only for GitHub first party actions as we trust them,
so minor/patch changes can safely be pulled in without code changes.

Changelog:
[Internal] [Changed] - Align github/* action versions on major

Reviewed By: cipolleschi, blakef

Differential Revision: D59959978

fbshipit-source-id: bb07ce0dfd74d9502a2ac0ea90a2b32f55d6d655
2024-07-19 05:49:03 -07:00

29 lines
1.0 KiB
YAML

name: setup-xcode-build-cache
description: Add caching to iOS jobs to speed up builds
inputs:
hermes-version:
description: The version of hermes
required: true
runs:
using: composite
steps:
- name: See commands.yml with_xcodebuild_cache
shell: bash
run: echo "See commands.yml with_xcodebuild_cache"
- name: Prepare Xcodebuild cache
shell: bash
run: |
WEEK=$(date +"%U")
YEAR=$(date +"%Y")
echo "$WEEK-$YEAR" > /tmp/week_year
- name: Cache podfile lock
uses: actions/cache@v4
with:
path: packages/rn-tester/Podfile.lock
key: v10-podfilelock-${{ github.job }}-${{ hashfiles('packages/rn-tester/Podfile') }}-${{ hashfiles('/tmp/week_year') }}-${{ inputs.hermes-version}}
- name: Cache cocoapods
uses: actions/cache@v4
with:
path: packages/rn-tester/Pods
key: v12-cocoapods-${{ github.job }}-${{ hashfiles('packages/rn-tester/Podfile.lock') }}-${{ hashfiles('packages/rn-tester/Podfile') }}-${{ inputs.hermes-version}}