mirror of
https://github.com/scratchfoundation/scratch-desktop.git
synced 2024-12-22 21:52:31 -05:00
use Fastlane Match in CI
This commit is contained in:
parent
3a95c0c213
commit
c0355803c7
1 changed files with 2 additions and 27 deletions
|
@ -47,33 +47,8 @@ jobs:
|
||||||
name: Import CI context
|
name: Import CI context
|
||||||
command: |
|
command: |
|
||||||
set -e
|
set -e
|
||||||
function decodeToFile () {
|
fastlane match_dev
|
||||||
if [ -z "$1" ]; then
|
fastlane match_dist
|
||||||
echo "Missing or invalid filename"
|
|
||||||
return 1
|
|
||||||
fi
|
|
||||||
if [ -z "$2" ]; then
|
|
||||||
echo "Missing environment variable contents for file: $1"
|
|
||||||
return 2
|
|
||||||
fi
|
|
||||||
echo "$2" | base64 --decode > "$1"
|
|
||||||
}
|
|
||||||
decodeToFile embedded.provisionprofile "${MAC_PROVISION_PROFILE}"
|
|
||||||
decodeToFile mas-dev.provisionprofile "${MAC_DEV_PROVISION_PROFILE}"
|
|
||||||
decodeToFile macos-certs-scratch-foundation.p12.gz "${CSC_MACOS_GZ}"
|
|
||||||
decodeToFile apple-dev-cert.p12 "${MAC_DEV_CERT}"
|
|
||||||
gunzip macos-certs-scratch-foundation.p12.gz
|
|
||||||
security -v create-keychain -p circleci circleci.keychain
|
|
||||||
security -v default-keychain -s circleci.keychain
|
|
||||||
security -v import macos-certs-scratch-foundation.p12 -k circleci.keychain -P "${CSC_MACOS_PASSWORD}" -T /usr/bin/codesign -T /usr/bin/productbuild
|
|
||||||
security -v import apple-dev-cert.p12 -k circleci.keychain -P "${MAC_DEV_CERT_PASSWORD}" -T /usr/bin/codesign -T /usr/bin/productbuild
|
|
||||||
security -v unlock-keychain -p circleci circleci.keychain
|
|
||||||
# "set-key-partition-list" prints extensive not-so-useful output and adding "-q" (even multiple times) doesn't suppress it.
|
|
||||||
# The "grep -v" at the end of this line suppresses all of that so any errors or warnings might be more visible.
|
|
||||||
security -v set-key-partition-list -S apple-tool:,apple:,codesign: -s -k circleci circleci.keychain | grep -v '^ 0x'
|
|
||||||
security -v set-keychain-settings -lut 600 circleci.keychain
|
|
||||||
security -v find-identity circleci.keychain
|
|
||||||
rm macos-certs-scratch-foundation.p12 apple-dev-cert.p12
|
|
||||||
- restore_cache:
|
- restore_cache:
|
||||||
# Caching Homebrew's files (see the save_cache step below) means that Homebrew doesn't have to update as
|
# Caching Homebrew's files (see the save_cache step below) means that Homebrew doesn't have to update as
|
||||||
# much. The Homebrew update can take several minutes without this, but with the cache it tends to take less
|
# much. The Homebrew update can take several minutes without this, but with the cache it tends to take less
|
||||||
|
|
Loading…
Reference in a new issue