File tree Expand file tree Collapse file tree 1 file changed +3
-1
lines changed
Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Original file line number Diff line number Diff line change @@ -161,9 +161,11 @@ jobs:
161161 run : git merge --continue
162162 - name : Add VERSION file if not present
163163 run : |
164+ is_version_file_present_upstream=$(git ls-tree ${{ steps.upstream.outputs.release }} | grep VERSION || true)
164165 # All tags use the vX.Y.Z format currently.
165166 version_from_tag=$(echo ${{ steps.upstream.outputs.release }} | sed -e "s/^v//")
166- if [ -f VERSION ]; then
167+ # Perform check only if both remotes have the VERSION file.
168+ if [ -n "$is_version_file_present_upstream" ] && [ -f VERSION ]; then
167169 version_from_file=$(cat VERSION)
168170 if [ "$version_from_tag" != "$version_from_file" ];then
169171 echo "::error:: tag version ${version_from_tag} doesn't correspond to version ${version_from_file} from VERSION file"
You can’t perform that action at this time.
0 commit comments