branching improvements

Fall back to git_remote() if git_repo_remote() (aka git_remote_fp) fails.

Fix failure to pass review_method to update_gitreview().

Signed-off-by: Scott Little <scott.little@windriver.com>
Change-Id: If1f63529160723a5065de3866b9679da312bcb94
This commit is contained in:
Scott Little
2025-10-02 12:47:46 -04:00
parent 5a135dab27
commit 0f9cc3be4b
2 changed files with 5 additions and 2 deletions

View File

@@ -418,7 +418,7 @@ for subgit in $SUBGITS; do
echo "Tag '$tag' already exists in ${subgit}"
fi
update_gitreview ${subgit} || exit 1
update_gitreview ${subgit} ${review_method} || exit 1
) || exit 1
done
) || exit 1

View File

@@ -488,7 +488,10 @@ git_remote_branch () {
# Before we can select a remote branch, we need to know which remote.
remote=$($git_remote_fp)
if [ $? -ne 0 ] || [ "$remote" == "" ]; then
return 1
remote=$(git_remote)
if [ $? -ne 0 ] || [ "$remote" == "" ]; then
return 1
fi
fi
# Find 'nearest' remote branch that we detached from and/or added commits to