Skip to content

Commit

Permalink
ci: sync upstream
Browse files Browse the repository at this point in the history
  • Loading branch information
yioneko committed Jul 17, 2024
1 parent ca812e4 commit e57f0a3
Showing 1 changed file with 45 additions and 0 deletions.
45 changes: 45 additions & 0 deletions .github/workflows/sync.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
name: 'Upstream Sync'

on:
schedule:
- cron: '0 0 * * 4'

workflow_dispatch:
inputs:
sync_test_mode:
description: 'Fork Sync Test Mode'
type: boolean
default: false

jobs:
sync_latest_from_upstream:
runs-on: ubuntu-latest
name: Sync latest commits from upstream repo

steps:
- name: Checkout target repo
uses: actions/checkout@v4
with:
ref: perf

- name: Sync upstream changes
id: sync
uses: aormsby/Fork-Sync-With-Upstream-action@v3.4
with:
target_sync_branch: perf
upstream_sync_branch: main
upstream_sync_repo: hrsh7th/nvim-cmp
test_mode: ${{ inputs.sync_test_mode }}
git_config_pull_rebase: true
target_branch_push_args: '--force'

- name: New commits found
if: steps.sync.outputs.has_new_commits == 'true'
run: echo "New commits were found to sync."

- name: No new commits
if: steps.sync.outputs.has_new_commits == 'false'
run: echo "There were no new commits."

- name: Show value of 'has_new_commits'
run: echo ${{ steps.sync.outputs.has_new_commits }}

0 comments on commit e57f0a3

Please sign in to comment.