mirror of
https://github.com/electron/electron.git
synced 2026-04-10 03:01:51 -04:00
build: add psuedocode for Azure workflow, add workflow_dispatch
This commit is contained in:
committed by
Shelley Vohr
parent
541fbc7264
commit
a2de07ad8a
115
.github/workflows/mac-build.yml
vendored
115
.github/workflows/mac-build.yml
vendored
@@ -1,7 +1,14 @@
|
||||
name: Build MacOS
|
||||
|
||||
on:
|
||||
push
|
||||
push:
|
||||
branches:
|
||||
- gh-mac-runner
|
||||
workflow_dispatch:
|
||||
inputs:
|
||||
branch:
|
||||
description: 'branch'
|
||||
required: true
|
||||
|
||||
env:
|
||||
GCLIENT_EXTRA_ARGS: '--custom-var=checkout_mac=True --custom-var=host_os=mac --custom-var=host_cpu=arm64'
|
||||
@@ -16,6 +23,9 @@ jobs:
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
path: src/electron
|
||||
- name: Install Azure CLI
|
||||
run: |
|
||||
brew update && brew install azure-cli
|
||||
- name: Setup Node/NPM
|
||||
uses: actions/setup-node@v3
|
||||
with:
|
||||
@@ -37,45 +47,66 @@ jobs:
|
||||
- run: echo "$PWD/depot_tools" >> $GITHUB_PATH
|
||||
- run: echo "$PATH"
|
||||
# step-gclient-sync, L287
|
||||
- name: Gclient Sync
|
||||
run: |
|
||||
# If we did not restore a complete sync then we need to sync for realz
|
||||
if [ ! -s "src/electron/.circle-sync-done" ]; then
|
||||
gclient config \
|
||||
--name "src/electron" \
|
||||
--unmanaged \
|
||||
$GCLIENT_EXTRA_ARGS \
|
||||
"$GITHUB_SERVER_URL/$GITHUB_REPOSITORY"
|
||||
# TODO(vertedinde): Re-enable sync after SSH debug integration is working
|
||||
# - name: Gclient Sync
|
||||
# run: |
|
||||
# # If we did not restore a complete sync then we need to sync for realz
|
||||
# if [ ! -s "src/electron/.circle-sync-done" ]; then
|
||||
# gclient config \
|
||||
# --name "src/electron" \
|
||||
# --unmanaged \
|
||||
# $GCLIENT_EXTRA_ARGS \
|
||||
# "$GITHUB_SERVER_URL/$GITHUB_REPOSITORY"
|
||||
|
||||
ELECTRON_USE_THREE_WAY_MERGE_FOR_PATCHES=1 gclient sync --with_branch_heads --with_tags -vvvvv
|
||||
if [ "$IS_RELEASE" != "true" ]; then
|
||||
# Re-export all the patches to check if there were changes.
|
||||
python3 src/electron/script/export_all_patches.py src/electron/patches/config.json
|
||||
cd src/electron
|
||||
# git update-index --refresh || true
|
||||
# TODO(vertedinde): Let's not stress on patchup right now, just sync it
|
||||
# if ! git diff-index --quiet HEAD --; then
|
||||
# # There are changes to the patches. Make a git commit with the updated patches
|
||||
# git add patches
|
||||
# GIT_COMMITTER_NAME="PatchUp" GIT_COMMITTER_EMAIL="73610968+patchup[bot]@users.noreply.github.com" git commit -m "chore: update patches" --author="PatchUp <73610968+patchup[bot]@users.noreply.github.com>"
|
||||
# # Export it
|
||||
# mkdir -p ../../patches
|
||||
# git format-patch -1 --stdout --keep-subject --no-stat --full-index > ../../patches/update-patches.patch
|
||||
# if (node ./script/push-patch.js 2> /dev/null > /dev/null); then
|
||||
# echo
|
||||
# echo "======================================================================"
|
||||
# echo "Changes to the patches when applying, we have auto-pushed the diff to the current branch"
|
||||
# echo "A new CI job will kick off shortly"
|
||||
# echo "======================================================================"
|
||||
# exit 1
|
||||
# else
|
||||
# echo
|
||||
# echo "======================================================================"
|
||||
# echo "There were changes to the patches when applying."
|
||||
# echo "Check the CI artifacts for a patch you can apply to fix it."
|
||||
# echo "======================================================================"
|
||||
# exit 1
|
||||
# fi
|
||||
# fi
|
||||
fi
|
||||
fi
|
||||
# ELECTRON_USE_THREE_WAY_MERGE_FOR_PATCHES=1 gclient sync --with_branch_heads --with_tags -vvvvv
|
||||
# if [ "$IS_RELEASE" != "true" ]; then
|
||||
# Re-export all the patches to check if there were changes.
|
||||
# python3 src/electron/script/export_all_patches.py src/electron/patches/config.json
|
||||
# cd src/electron
|
||||
# git update-index --refresh || true
|
||||
# TODO(vertedinde): Let's not stress on patchup right now, just sync it
|
||||
# if ! git diff-index --quiet HEAD --; then
|
||||
# # There are changes to the patches. Make a git commit with the updated patches
|
||||
# git add patches
|
||||
# GIT_COMMITTER_NAME="PatchUp" GIT_COMMITTER_EMAIL="73610968+patchup[bot]@users.noreply.github.com" git commit -m "chore: update patches" --author="PatchUp <73610968+patchup[bot]@users.noreply.github.com>"
|
||||
# # Export it
|
||||
# mkdir -p ../../patches
|
||||
# git format-patch -1 --stdout --keep-subject --no-stat --full-index > ../../patches/update-patches.patch
|
||||
# if (node ./script/push-patch.js 2> /dev/null > /dev/null); then
|
||||
# echo
|
||||
# echo "======================================================================"
|
||||
# echo "Changes to the patches when applying, we have auto-pushed the diff to the current branch"
|
||||
# echo "A new CI job will kick off shortly"
|
||||
# echo "======================================================================"
|
||||
# exit 1
|
||||
# else
|
||||
# echo
|
||||
# echo "======================================================================"
|
||||
# echo "There were changes to the patches when applying."
|
||||
# echo "Check the CI artifacts for a patch you can apply to fix it."
|
||||
# echo "======================================================================"
|
||||
# exit 1
|
||||
# fi
|
||||
# fi
|
||||
# fi
|
||||
# fi
|
||||
# # step-gclient-sync, L976
|
||||
# - name: Generate DEPS Hash
|
||||
# run: |
|
||||
# node src/electron/script/generate-deps-hash.js && cat src/electron/.depshash-target
|
||||
# - name: Minimize the size of the cache
|
||||
# run: |
|
||||
# cd src
|
||||
# rm -rf src/android_webview
|
||||
# rm -rf src/ios/chrome
|
||||
# rm -rf src/third_party/blink/web_tests
|
||||
# rm -rf src/third_party/blink/perf_tests
|
||||
# rm -rf third_party/electron_node/deps/openssl
|
||||
# rm -rf third_party/electron_node/deps/v8
|
||||
# rm -rf chrome/test/data/xr/webvr_info
|
||||
# rm -rf src/third_party/angle/third_party/VK-GL-CTS/src
|
||||
# rm -rf src/third_party/swift-toolchain
|
||||
# rm -rf src/third_party/swiftshader/tests/regres/testlists
|
||||
# - name: Generate & Upload Azure CLI Blob
|
||||
# run: |
|
||||
# # sudo code
|
||||
|
||||
Reference in New Issue
Block a user