Re: [PATCH v8 4/7] bisect: introduce --no-checkout, --update-ref=<ref> support into porcelain.
- From
Christian Couder <christian.couder@gmail.com>
- Date
- Jul 31, 2011, 18:35 UTC
- Message-ID
- <CAP8UFD2uWRS4KznUAQCCF8sShGy6+sGWgNsLj8mmO7Ur1CDrCQ@mail.gmail.com>
- In-Reply-To
- <1312113321-28760-5-git-send-email-jon.seymour@gmail.com>
On Sun, Jul 31, 2011 at 1:55 PM, Jon Seymour <jon.seymour@gmail.com> wrote:
Show 14 quoted lines
>
> @@ -69,13 +71,18 @@ bisect_start() {
> orig_args=$(git rev-parse --sq-quote "$@")
> bad_seen=0
> eval=''
> + BISECT_UPDATE_REF=
> while [ $# -gt 0 ]; do
> arg="$1"
> case "$arg" in
> --)
> - shift
> - break
> - ;;
> + shift; break ;;Please don't change this. We try to avoid having many instructions on the same line like this.
> + --no-checkout) > + BISECT_UPDATE_REF=HEAD; shift ;;
Perhaps:
test -z "$BISECT_UPDATE_REF" && BISECT_UPDATE_REF=HEAD
so that "--update-ref=someref --no-checkout" works the same as "--no-checkout --update-ref=someref".
Show 7 quoted lines
> + --update-ref=*)
> + BISECT_UPDATE_REF=${arg#--update-ref=}; shift ;;
> + --*)
> + die "$(eval_gettext "unrecognised option: '\$arg'")" ;;
> *)
> rev=$(git rev-parse -q --verify "$arg^{commit}") || {
> test $has_double_dash -eq 1 &&Thanks, Christian.