diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-07 14:47:53 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-07 14:47:53 +0000 |
commit | c8bae7493d2f2910b57f13ded012e86bdcfb0532 (patch) | |
tree | 24e09d9f84dec336720cf393e156089ca2835791 /git-bisect.sh | |
parent | Initial commit. (diff) | |
download | git-c8bae7493d2f2910b57f13ded012e86bdcfb0532.tar.xz git-c8bae7493d2f2910b57f13ded012e86bdcfb0532.zip |
Adding upstream version 1:2.39.2.upstream/1%2.39.2upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'git-bisect.sh')
-rwxr-xr-x | git-bisect.sh | 67 |
1 files changed, 67 insertions, 0 deletions
diff --git a/git-bisect.sh b/git-bisect.sh new file mode 100755 index 0000000..dfce4b4 --- /dev/null +++ b/git-bisect.sh @@ -0,0 +1,67 @@ +#!/bin/sh + +USAGE='[help|start|bad|good|new|old|terms|skip|next|reset|visualize|view|replay|log|run]' +LONG_USAGE='git bisect help + print this long help message. +git bisect start [--term-{new,bad}=<term> --term-{old,good}=<term>] + [--no-checkout] [--first-parent] [<bad> [<good>...]] [--] [<pathspec>...] + reset bisect state and start bisection. +git bisect (bad|new) [<rev>] + mark <rev> a known-bad revision/ + a revision after change in a given property. +git bisect (good|old) [<rev>...] + mark <rev>... known-good revisions/ + revisions before change in a given property. +git bisect terms [--term-good | --term-bad] + show the terms used for old and new commits (default: bad, good) +git bisect skip [(<rev>|<range>)...] + mark <rev>... untestable revisions. +git bisect next + find next bisection to test and check it out. +git bisect reset [<commit>] + finish bisection search and go back to commit. +git bisect (visualize|view) + show bisect status in gitk. +git bisect replay <logfile> + replay bisection log. +git bisect log + show bisect log. +git bisect run <cmd>... + use <cmd>... to automatically bisect. + +Please use "git help bisect" to get the full man page.' + +OPTIONS_SPEC= +. git-sh-setup + +TERM_BAD=bad +TERM_GOOD=good + +get_terms () { + if test -s "$GIT_DIR/BISECT_TERMS" + then + { + read TERM_BAD + read TERM_GOOD + } <"$GIT_DIR/BISECT_TERMS" + fi +} + +case "$#" in +0) + usage ;; +*) + cmd="$1" + get_terms + shift + case "$cmd" in + help) + git bisect -h ;; + bad|good|new|old|"$TERM_BAD"|"$TERM_GOOD") + git bisect--helper state "$cmd" "$@" ;; + log) + git bisect--helper log || exit ;; + *) + git bisect--helper "$cmd" "$@" ;; + esac +esac |