From 058f063b8f038bfef2ae9b4989868359a0c1973d Mon Sep 17 00:00:00 2001 From: dbaranov34 Date: Tue, 2 Jul 2024 14:44:03 +0400 Subject: [PATCH] script to prefer version from upstream --- .github/workflows/sync.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/sync.yml b/.github/workflows/sync.yml index 46303d754..f977f344a 100644 --- a/.github/workflows/sync.yml +++ b/.github/workflows/sync.yml @@ -29,8 +29,8 @@ jobs: - name: Sync branches run: | for branch in $(git branch -r | grep upstream | grep -v '\->' | sed 's|upstream/||'); do - git checkout $branch || git checkout -b $branch - git merge upstream/$branch --allow-unrelated-histories + git checkout $branch 2>/dev/null || git checkout -b $branch upstream/$branch + git merge upstream/$branch --strategy-option theirs || git checkout --theirs . done - name: Push changes