X-Git-Url: http://git.ozlabs.org/?a=blobdiff_plain;ds=sidebyside;f=merge_fix;h=9048251a23ab422c5be3df87d12c2a6ce82c36c5;hb=HEAD;hp=27db62fd6e079806b68a04ce83b58c3cf24fca2f;hpb=4105f526175d8fd8726d8e56a2fcca7edb94d8c0;p=next-scripts diff --git a/merge_fix b/merge_fix index 27db62f..9048251 100755 --- a/merge_fix +++ b/merge_fix @@ -1,13 +1,5 @@ #!/bin/bash -bin_dir="$(dirname $0)" - -LOG_FILE="../merge.log" -build_host="ka2" -build_dir="/scratch/sfr/next" -[ "$NEXT_BUILD_HOST" ] && build_host="$NEXT_BUILD_HOST" -[ "$NEXT_BUILD_DIR" ] && build_dir="$NEXT_BUILD_DIR" - no_build=false [ "$1" = "-n" ] && { shift @@ -19,17 +11,8 @@ shift echo "patch does not exist" 1>&2 exit 1 } -[ -n "$1" ] && { - build_host="$1" - shift -} -[ -n "$1" ] && { - build_dir="$1" - shift -} -export NEXT_BUILD_HOST="$build_host" -export NEXT_BUILD_DIR="$build_dir" +. "$(dirname $0)/common.sh" log() { @@ -73,7 +56,7 @@ GIT_EDITOR=: execute git commit -v -a --amend || { $no_build && exit 0 -git push -f "$build_host":"$build_dir" master:refs/heads/next || { +git push -f "${build_host}${build_host:+:}${build_dir}" master:refs/heads/next || { echo git push failed 1>&2 bash -i || exit }