From 9224893caeb7a2d8c71d8faeeda888fc3bef0a76 Mon Sep 17 00:00:00 2001 From: hiletmis <31757771+hiletmis@users.noreply.github.com> Date: Tue, 12 Nov 2024 17:45:00 +0300 Subject: [PATCH] Update diff check command in version-check workflow to use 'main' branch and set environment variable --- .github/workflows/version-check.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/version-check.yml b/.github/workflows/version-check.yml index 781ab8f6..0cb9a19d 100644 --- a/.github/workflows/version-check.yml +++ b/.github/workflows/version-check.yml @@ -38,9 +38,9 @@ jobs: - name: Diff Check id: diff-check run: | - git diff HEAD control-branch --name-only - if [ $? -eq 1 ]; then - echo "changes_detected=true" >> "$GITHUB_OUTPUT" + git diff main control-branch --name-only + if [[ $(git diff main control-branch --name-only) ]]; then + echo "changes_detected=true" >> "$GITHUB_ENV" fi - name: Commit changes uses: stefanzweifel/git-auto-commit-action@v5