Re: git-bisect feature suggestion: "git-bisect diff"

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

 



Ingo Molnar <mingo@xxxxxxx> writes:

> would be nice to have:
>
>  git-bisect diff
>
> that enables one to have a look at the currently open bisection window, 
> in git-log -p format. This would often be much faster to analyze than 
> looking at git-bisect visualize. (and it could also be used in non-GUI 
> workflows)

Hmm.  It is very unfortunate that "bisect log" is taken for something
unrelated, so tentatively let's call it lumber.

	$ git bisect lumber [-p] [--stat]

would give you the short-hand, hopefully.

---

 git-bisect.sh |   12 +++++++++++-
 1 files changed, 11 insertions(+), 1 deletions(-)

diff --git a/git-bisect.sh b/git-bisect.sh
index 7a6521e..ee26624 100755
--- a/git-bisect.sh
+++ b/git-bisect.sh
@@ -1,6 +1,6 @@
 #!/bin/sh
 
-USAGE='[start|bad|good|skip|next|reset|visualize|replay|log|run]'
+USAGE='[start|bad|good|skip|next|reset|visualize|log|replay|lumber|run]'
 LONG_USAGE='git bisect start [<bad> [<good>...]] [--] [<pathspec>...]
         reset bisect state and start bisection.
 git bisect bad [<rev>]
@@ -15,6 +15,8 @@ git bisect reset [<branch>]
         finish bisection search and go back to branch.
 git bisect visualize
         show bisect status in gitk.
+git bisect lumber
+        show bisect status in git log.
 git bisect replay <logfile>
         replay bisection log.
 git bisect log
@@ -328,6 +330,12 @@ bisect_visualize() {
 	eval gitk refs/bisect/bad --not $not -- $(cat "$GIT_DIR/BISECT_NAMES")
 }
 
+bisect_lumber() {
+	bisect_next_check fail
+	not=$(git for-each-ref --format='%(refname)' "refs/bisect/good-*")
+	eval git log "$@" refs/bisect/bad --not $not -- $(cat "$GIT_DIR/BISECT_NAMES")
+}
+
 bisect_reset() {
 	test -f "$GIT_DIR/BISECT_NAMES" || {
 		echo "We are not bisecting."
@@ -451,6 +459,8 @@ case "$#" in
         bisect_next "$@" ;;
     visualize)
 	bisect_visualize "$@" ;;
+    lumber)
+	bisect_lumber "$@" ;;
     reset)
         bisect_reset "$@" ;;
     replay)
-
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]

  Powered by Linux