Sync from Upstream LLVM #816
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# This workflow fetches changes from relevant branches from the | |
# llvm/llvm-project repository (upstream) into the corresponding branches | |
# in the arm/arm-toolchain repository (downstream), keeping them in sync. | |
name: Sync from Upstream LLVM | |
on: | |
schedule: | |
- cron: '0,30 * * * *' | |
workflow_dispatch: | |
jobs: | |
Fetch-Upstream: | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
branch: [main, release/19.x] | |
env: | |
UPSTREAM_REMOTE: https://github.com/llvm/llvm-project.git | |
steps: | |
- name: Configure Access Token | |
uses: actions/create-github-app-token@v1 | |
id: generate-token | |
with: | |
app-id: ${{ secrets.SYNC_APP_ID }} | |
private-key: ${{ secrets.SYNC_APP_PRIVATE_KEY }} | |
- name: Checkout | |
uses: actions/checkout@v4 | |
with: | |
ref: ${{ matrix.branch }} | |
token: ${{ steps.generate-token.outputs.token }} | |
- name: Configure Upstream Remote | |
run: git remote add upstream ${{ env.UPSTREAM_REMOTE }} | |
- name: Fetch Upstream Changes | |
run: git pull --ff-only upstream ${{ matrix.branch }} | |
- name: Configure Git Identity | |
run: | | |
git config --local user.name "github-actions[bot]" | |
git config --local user.email "41898282+github-actions[bot]@users.noreply.github.com" | |
- name: Push Changes | |
run: git push origin ${{ matrix.branch }} |