Use cache

This commit is contained in:
Mingshen Sun 2020-12-30 10:44:57 -08:00
parent 6050903a1f
commit 40fc12d02c
5 changed files with 41 additions and 6 deletions

View file

@ -11,12 +11,30 @@ jobs:
run: |
brew install libtool automake cmake carthage go@1.14 swiftlint swiftformat
gem install bundler
- name: Preparing dependencies
bundle install
- uses: actions/cache@v2
id: carthage-cache
with:
path: Carthage
key: ${{ runner.os }}-carthage-${{ hashFiles('**/Cartfile.resolved') }}
restore-keys: |
${{ runner.os }}-carthage-
- uses: actions/cache@v2
id: pods-cache
with:
path: Pods
key: ${{ runner.os }}-pods-${{ hashFiles('**/Podfile.lock') }}
restore-keys: |
${{ runner.os }}-pods-
- name: Carthage
if: steps.carthage-cache.outputs.cache-hit != 'true'
run: ./scripts/wcarthage bootstrap --platform iOS --no-use-binaries --cache-builds
- name: Cocoapods
if: steps.pods-cache.outputs.cache-hit != 'true'
run: bundle exec pod install
- name: GopenPGP
run: |
export PATH="/usr/local/opt/go@1.14/bin:$PATH"
bundle install
bundle exec pod install
./scripts/wcarthage bootstrap --platform iOS
./scripts/gopenpgp_build.sh
- name: Testing
run: bundle exec fastlane test