diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 89575d1cc..721edc9a2 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -248,8 +248,8 @@ jobs: - name: Setup Git run: | - git config --global user.email "mauro-balades@users.noreply.github.com" - git config --global user.name "mauro-balades" + git config --global user.name "github-actions[bot]" + git config --global user.email "github-actions[bot]@users.noreply.github.com" - name: Install dependencies run: | diff --git a/.github/workflows/linux-release-build.yml b/.github/workflows/linux-release-build.yml index cbde15856..93c6a70da 100644 --- a/.github/workflows/linux-release-build.yml +++ b/.github/workflows/linux-release-build.yml @@ -70,8 +70,8 @@ jobs: - name: Setup Git run: | - git config --global user.email "mauro-balades@users.noreply.github.com" - git config --global user.name "mauro-balades" + git config --global user.name "github-actions[bot]" + git config --global user.email "github-actions[bot]@users.noreply.github.com" - name: Install system dependencies run: | diff --git a/.github/workflows/macos-release-build.yml b/.github/workflows/macos-release-build.yml index 877fbb604..5b09a5706 100644 --- a/.github/workflows/macos-release-build.yml +++ b/.github/workflows/macos-release-build.yml @@ -68,8 +68,8 @@ jobs: - name: Setup Git run: | - git config --global user.email "mauro-balades@users.noreply.github.com" - git config --global user.name "mauro-balades" + git config --global user.name "github-actions[bot]" + git config --global user.email "github-actions[bot]@users.noreply.github.com" - name: Install system dependencies run: | diff --git a/.github/workflows/macos-universal-release-build.yml b/.github/workflows/macos-universal-release-build.yml index ea9063d8d..dbc2130f0 100644 --- a/.github/workflows/macos-universal-release-build.yml +++ b/.github/workflows/macos-universal-release-build.yml @@ -38,8 +38,8 @@ jobs: - name: Setup Git run: | - git config --global user.email "mauro-balades@users.noreply.github.com" - git config --global user.name "mauro-balades" + git config --global user.name "github-actions[bot]" + git config --global user.email "github-actions[bot]@users.noreply.github.com" - name: Install system dependencies run: | diff --git a/.github/workflows/sync-external-patches.yml b/.github/workflows/sync-external-patches.yml new file mode 100644 index 000000000..2fc79d586 --- /dev/null +++ b/.github/workflows/sync-external-patches.yml @@ -0,0 +1,70 @@ +name: Sync External Patches + +on: + workflow_dispatch: + +permissions: + contents: write + +jobs: + check_candidates: + name: Sync External Patches + runs-on: ubuntu-latest + + steps: + - name: Check out repository + uses: actions/checkout@v3 + + - name: Setup Python + uses: actions/setup-python@v5 + # note: This will use the version defined in '.python-version' by defaultç + + - name: Install dependencies + run: | + git config --global user.name "github-actions[bot]" + git config --global user.email "github-actions[bot]@users.noreply.github.com" + + - name: Import external patches + run: python3 scripts/import_external_patches.py + + - name: Check if any files changed + id: git-check + run: | + if [ -n "$(git status --porcelain)" ]; then + echo "files_changed=true" >> $GITHUB_OUTPUT + else + echo "files_changed=false" >> $GITHUB_OUTPUT + fi + + - name: Download Firefox and dependencies + if: steps.git-check.outputs.files_changed == 'true' + run: npm run download + + - name: Check if patches got applied + if: steps.git-check.outputs.files_changed == 'true' + id: check-patches + continue-on-error: true + run: | + echo "Checking if patches apply cleanly..." + npm run import + + - name: Create pull request + uses: peter-evans/create-pull-request@v7 + if: steps.git-check.outputs.files_changed == 'true' + env: + GIT_TRACE: 1 + GIT_CURL_VERBOSE: 1 + with: + token: ${{ secrets.DEPLOY_KEY }} + commit-message: "chore: Sync external patches" + branch: "chore/sync-external-patches-${{ github.run_id }}" + title: "Sync external patches" + body: | + This PR syncs the external patches automatically. + + * ${{ steps.check-patches.outcome == 'failure' && '⚠️ Some patches did not apply cleanly. Please review them carefully.' || '✅ All patches applied cleanly.' }} + + @${{ github.actor }} please review and merge this PR. Generated from workflow run [${{ github.run_id }}](${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}), branch ${{ github.head_ref }}. + base: dev + git-token: ${{ secrets.DEPLOY_KEY }} + delete-branch: true diff --git a/.github/workflows/sync-upstream.yml b/.github/workflows/sync-upstream.yml index efc4c79f5..6d7e3aec3 100644 --- a/.github/workflows/sync-upstream.yml +++ b/.github/workflows/sync-upstream.yml @@ -50,8 +50,8 @@ jobs: - name: Install dependencies if: steps.check-upstream-branch.outputs.branch_exists == 'false' run: | - git config --global user.email "mr-cheffy@users.noreply.github.com" - git config --global user.name "mr-cheffy" + git config --global user.name "github-actions[bot]" + git config --global user.email "github-actions[bot]@users.noreply.github.com" - name: Setup surfer CI if: steps.check-upstream-branch.outputs.branch_exists == 'false' diff --git a/.github/workflows/windows-profile-build.yml b/.github/workflows/windows-profile-build.yml index 04df4a057..740c5fd3f 100644 --- a/.github/workflows/windows-profile-build.yml +++ b/.github/workflows/windows-profile-build.yml @@ -41,8 +41,8 @@ jobs: - name: Setup Git run: | - git config --global user.email "mauro-balades@users.noreply.github.com" - git config --global user.name "mauro-balades" + git config --global user.name "github-actions[bot]" + git config --global user.email "github-actions[bot]@users.noreply.github.com" - name: Install Surfer run: npm i -g @zen-browser/surfer diff --git a/.github/workflows/windows-release-build.yml b/.github/workflows/windows-release-build.yml index 43934dfee..8db2042ea 100644 --- a/.github/workflows/windows-release-build.yml +++ b/.github/workflows/windows-release-build.yml @@ -79,8 +79,8 @@ jobs: - name: Setup Git run: | - git config --global user.email "mauro-balades@users.noreply.github.com" - git config --global user.name "mauro-balades" + git config --global user.name "github-actions[bot]" + git config --global user.email "github-actions[bot]@users.noreply.github.com" - name: Install dependencies run: |