Skip to content

Sync Upstream

Sync Upstream #136

Workflow file for this run

name: Sync Upstream
on:
# To make debugging easier, run on pushes to the "custom" branch
push:
branches: [ 'custom' ]
# Run scheduled once a day
schedule:
- cron: '0 0 * * *'
# Allow running manually
workflow_dispatch:
inputs:
ref:
type: string
description: 'Target reference (eg. branch, tag etc.)'
required: true
default: 'kernel-5.16'
force:
type: boolean
description: 'Forced build and deploy (also updates cache)'
required: false
default: false
jobs:
sync-upstream:
name: Sync Upstream
runs-on: ubuntu-latest
timeout-minutes: 15
steps:
# Checkout the target repository (this repo)
- name: Checkout Repository
uses: actions/checkout@v3
with:
# Always pull the requested ref, or a hardcoded fallback value
ref: ${{ github.event.inputs.ref || 'kernel-5.16' }}
# No need to persist credentials in this case
persist-credentials: false
# Sync upstream repository (with automatic retry support)
- name: Sync Upstream Repository
id: sync
#uses: Wandalen/wretry.action@master
uses: Wandalen/[email protected]
with:
# Attempt 3 times before giving up
attempt_limit: 3
# Delay each attempt by 1 minute
attempt_delay: 60000
# The action to run and retry on failure
action: aormsby/[email protected]
# The arguments for the retry action above
with: |
upstream_sync_repo: bigtreetech/CB1-Kernel
upstream_sync_branch: ${{ github.event.inputs.ref || 'kernel-5.16' }}
upstream_pull_args: '-s recursive -Xtheirs --allow-unrelated-histories --unshallow'
target_sync_branch: ${{ github.event.inputs.ref || 'kernel-5.16' }}
target_branch_push_args: '--force --all'
target_repo_token: ${{ secrets.GITHUB_TOKEN }}
shallow_since: '6 months ago'
git_config_pull_rebase: true
test_mode: false