Skip to content

Commit

Permalink
fix(macos): notarize
Browse files Browse the repository at this point in the history
  • Loading branch information
daiyam committed Jun 1, 2024
1 parent e2169a6 commit acedbcf
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 4 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/insider-macos.yml
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ jobs:
env:
CERTIFICATE_OSX_APP_PASSWORD: ${{ secrets.CERTIFICATE_OSX_NEW_APP_PASSWORD }}
CERTIFICATE_OSX_ID: ${{ secrets.CERTIFICATE_OSX_NEW_ID }}
CERTIFICATE_OSX_P12_FILE: ${{ secrets.CERTIFICATE_OSX_NEW_P12_FILE }}
CERTIFICATE_OSX_P12_DATA: ${{ secrets.CERTIFICATE_OSX_NEW_P12_DATA }}
CERTIFICATE_OSX_P12_PASSWORD: ${{ secrets.CERTIFICATE_OSX_NEW_P12_PASSWORD }}
run: ./prepare_assets.sh
if: env.SHOULD_BUILD == 'yes' && (env.SHOULD_DEPLOY == 'yes' || github.event.inputs.generate_assets == 'true')
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/stable-macos.yml
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ jobs:
env:
CERTIFICATE_OSX_APP_PASSWORD: ${{ secrets.CERTIFICATE_OSX_NEW_APP_PASSWORD }}
CERTIFICATE_OSX_ID: ${{ secrets.CERTIFICATE_OSX_NEW_ID }}
CERTIFICATE_OSX_P12_FILE: ${{ secrets.CERTIFICATE_OSX_NEW_P12_FILE }}
CERTIFICATE_OSX_P12_DATA: ${{ secrets.CERTIFICATE_OSX_NEW_P12_DATA }}
CERTIFICATE_OSX_P12_PASSWORD: ${{ secrets.CERTIFICATE_OSX_NEW_P12_PASSWORD }}
run: ./prepare_assets.sh
if: env.SHOULD_BUILD == 'yes' && (env.SHOULD_DEPLOY == 'yes' || github.event.inputs.generate_assets == 'true')
Expand Down
3 changes: 1 addition & 2 deletions prepare_assets.sh
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ if [[ "${OS_NAME}" == "osx" ]]; then
echo "AGENT_TEMPDIRECTORY: ${AGENT_TEMPDIRECTORY}"
echo "RUNNER_TEMP: ${RUNNER_TEMP}"

echo "${CERTIFICATE_OSX_P12_FILE}" | base64 --decode > "${CERTIFICATE_P12}"
echo "${CERTIFICATE_OSX_P12_DATA}" | base64 --decode > "${CERTIFICATE_P12}"

echo "+ create temporary keychain"
security create-keychain -p pwd "${KEYCHAIN}"
Expand All @@ -37,7 +37,6 @@ if [[ "${OS_NAME}" == "osx" ]]; then
security import "${CERTIFICATE_P12}" -k "${KEYCHAIN}" -P "${CERTIFICATE_OSX_P12_PASSWORD}" -T /usr/bin/codesign

CODESIGN_IDENTITY="$( security find-identity -v -p codesigning "${KEYCHAIN}" | grep -oEi "([0-9A-F]{40})" | head -n 1 )"
echo "CODESIGN_IDENTITY: ${CODESIGN_IDENTITY}"
export CODESIGN_IDENTITY

security set-key-partition-list -S apple-tool:,apple:,codesign: -s -k pwd "${KEYCHAIN}" > /dev/null
Expand Down

0 comments on commit acedbcf

Please sign in to comment.