diff options
Diffstat (limited to 'dev/tools')
| -rwxr-xr-x | dev/tools/backport-pr.sh | 2 | ||||
| -rwxr-xr-x | dev/tools/generate-release-changelog.sh | 4 | ||||
| -rwxr-xr-x | dev/tools/merge-pr.sh | 2 |
3 files changed, 4 insertions, 4 deletions
diff --git a/dev/tools/backport-pr.sh b/dev/tools/backport-pr.sh index b1d2fd656a..3fdc82b81b 100755 --- a/dev/tools/backport-pr.sh +++ b/dev/tools/backport-pr.sh @@ -30,7 +30,7 @@ while [[ $# -gt 0 ]]; do esac done -REMOTE=$(git config --get "branch.master.remote") +REMOTE=$(git config --get "branch.master.remote" || true) if [ -z "$REMOTE" ]; then echo "Branch master has no remote. Using the local state of the master branch instead." MASTER=master diff --git a/dev/tools/generate-release-changelog.sh b/dev/tools/generate-release-changelog.sh index 5b2d749b66..4533d39adc 100755 --- a/dev/tools/generate-release-changelog.sh +++ b/dev/tools/generate-release-changelog.sh @@ -31,14 +31,14 @@ if ! git diff --quiet; then ask_confirmation fi -remote=$(git config --get "branch.${branch}.remote") +remote=$(git config --get "branch.${branch}.remote" || true) if [ -z "$remote" ]; then echo "Warning: branch $branch has no associated remote." ask_confirmation else - if [ "$remote" != $(git config --get "branch.master.remote") ]; then + if [ "$remote" != $(git config --get "branch.master.remote" || true) ]; then echo "Warning: branch master and branch $branch do not have the same remote." ask_confirmation fi diff --git a/dev/tools/merge-pr.sh b/dev/tools/merge-pr.sh index 82e4bd1e1e..7b450c3e53 100755 --- a/dev/tools/merge-pr.sh +++ b/dev/tools/merge-pr.sh @@ -99,7 +99,7 @@ info "PR $PR targets branch $BASE_BRANCH" CURRENT_LOCAL_BRANCH=$(git rev-parse --abbrev-ref HEAD) info "you are merging in $CURRENT_LOCAL_BRANCH" -REMOTE=$(git config --get "branch.$CURRENT_LOCAL_BRANCH.remote") +REMOTE=$(git config --get "branch.$CURRENT_LOCAL_BRANCH.remote" || true) if [ -z "$REMOTE" ]; then error "branch $CURRENT_LOCAL_BRANCH has not associated remote" error "don't know where to fetch the PR from" |
