Re: [PATCH] pull: fix 'git pull --all' when current branch is tracking remote that is not last in the list of remotes

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Michael Lukashov <michael.lukashov@xxxxxxxxx> writes:

> diff --git a/git-pull.sh b/git-pull.sh
> index 38331a8..fcde096 100755
> --- a/git-pull.sh
> +++ b/git-pull.sh
> @@ -214,7 +214,11 @@ test true = "$rebase" && {
>  	done
>  }
>  orig_head=$(git rev-parse -q --verify HEAD)
> -git fetch $verbosity --update-head-ok "$@" || exit 1
> +if test -e "$GIT_DIR"/FETCH_HEAD
> +then
> +	rm "$GIT_DIR"/FETCH_HEAD 2>/dev/null
> +fi

When is it sane to ignore an error from this "rm", especially after you
made sure that it exists?
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]