[PATCH:util/modular] release.sh: use the remote consistently.

Jeremy Huddleston jeremyhu at freedesktop.org
Thu Nov 19 16:40:34 PST 2009


Reviewed-by: Jeremy Huddleston <jeremyhu at apple.com>

On Nov 19, 2009, at 16:14, Peter Hutterer wrote:

> Don't just use the specified remote for the git push, also check on the
> remote for the tag names, etc.
> 
> Signed-off-by: Peter Hutterer <peter.hutterer at who-t.net>
> ---
> release.sh |    8 ++++----
> 1 files changed, 4 insertions(+), 4 deletions(-)
> 
> diff --git a/release.sh b/release.sh
> index a2f5b0b..d7b88da 100755
> --- a/release.sh
> +++ b/release.sh
> @@ -138,7 +138,7 @@ fi
> 
> # Check if the object has been pushed. Do do so
> # 1. Check if the current branch has the object. If not, abort.
> -# 2. Check if the object is on origin/branchname. If not, abort.
> +# 2. Check if the object is on $remote/branchname. If not, abort.
> local_sha=`git rev-list -1 $tag_current`
> current_branch=`git branch | grep "\*" | sed -e "s/\* //"`
> set +e
> @@ -149,12 +149,12 @@ if [ $? -eq 1 ]; then
>     exit 1
> fi
> 
> -revs=`git rev-list origin/$current_branch..$current_branch | wc -l`
> +revs=`git rev-list $remote/$current_branch..$current_branch | wc -l`
> if [ $revs -ne 0 ]; then
> -    git rev-list origin/$current_branch..$current_branch | grep $local_sha > /dev/null
> +    git rev-list $remote/$current_branch..$current_branch | grep $local_sha > /dev/null
> 
>     if [ $? -ne 1 ]; then
> -        echo "origin/$current_branch doesn't have object $local_sha"
> +        echo "$remote/$current_branch doesn't have object $local_sha"
>         echo "for tag '$tag_current'. Did you push branch first? Aborting."
>         exit 1
>     fi
> -- 
> 1.6.5.2
> _______________________________________________
> xorg-devel mailing list
> xorg-devel at lists.x.org
> http://lists.x.org/mailman/listinfo/xorg-devel

-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 5820 bytes
Desc: not available
Url : http://lists.x.org/archives/xorg-devel/attachments/20091119/4247bc79/attachment.bin 


More information about the xorg-devel mailing list