Commit graph

44 commits

Author SHA1 Message Date
Christian Couder 69a9cd31b1 Documentation: add "Fighting regressions with git bisect" article
This patch adds an asciidoc version of the "Fighting regressions with
git bisect" article that the author wrote for the Linux-Kongress
2009 (http://www.linux-kongress.org/2009).

This paper might be interesting to people who want to learn as much as
possible about "git bisect" from a single document.

The slides of the related presentation are available at:

http://www.linux-kongress.org/2009/slides/fighting_regressions_with_git_bisect_christian_couder.pdf

But the Linux Kongress people will not publish this paper online because
they print the papers on their UpTimes magazine
(http://www.lob.de/isbn/978-3-86541-358-1). But they don't take away the
rights of the author (which is very nice), so I have the right to publish
it.

Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-11-08 18:29:08 -08:00
Anders Kaseorg 6b87ce231d bisect reset: Allow resetting to any commit, not just a branch
‘git bisect reset’ accepts an optional argument specifying a branch to
check out after cleaning up the bisection state.  This lets you
specify an arbitrary commit.

In particular, this provides a way to clean the bisection state
without moving HEAD: ‘git bisect reset HEAD’.  This may be useful if
you are not interested in the state before you began a bisect,
especially if checking out the old commit would be expensive and
invalidate most of your compiled tree.

Clarify the ‘git bisect reset’ documentation to explain this optional
argument, which was previously mentioned only in the usage message.

Signed-off-by: Anders Kaseorg <andersk@mit.edu>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-10-13 23:19:02 -07:00
Christian Couder 32d86ca531 Documentation: remove warning saying that "git bisect skip" may slow bisection
This warning was probably useless anyway, but it is even more so now
that filtering of skipped commits is done in C and that there is a
mechanism to skip away from broken commits.

Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-06-13 10:48:59 -07:00
Junio C Hamano 0b3035fe15 Merge branch 'dm/maint-docco'
* dm/maint-docco:
  Documentation: Remove spurious uses of "you" in git-bisect.txt.
  Documentation: minor grammatical fix in git-check-ref-format.txt
  Documentation: minor grammatical fixes in git-check-attr.txt
  Documentation: minor grammatical fixes in git-cat-file.txt
  Documentation: minor grammatical fixes and rewording in git-bundle.txt
  Documentation: remove some uses of the passive voice in git-bisect.txt
2009-03-26 00:26:04 -07:00
David J. Mellor 19fa5e8c4d Documentation: Remove spurious uses of "you" in git-bisect.txt.
These were added by accident in a42dea3.

This patch also rewords the description of how ranges of commits can be
skipped.

Signed-off-by: David J. Mellor <dmellor@whistlingcat.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-03-25 20:47:29 -07:00
David J. Mellor a42dea3281 Documentation: remove some uses of the passive voice in git-bisect.txt
Signed-off-by: David J. Mellor <dmellor@whistlingcat.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-03-22 20:58:16 -07:00
Junio C Hamano 88f78ce843 Merge branch 'dm/maint-docco'
* dm/maint-docco:
  Documentation: reword example text in git-bisect.txt.
  Documentation: reworded the "Description" section of git-bisect.txt.
  Documentation: minor grammatical fixes in git-branch.txt.
  Documentation: minor grammatical fixes in git-blame.txt.
  Documentation: reword the "Description" section of git-bisect.txt.
  Documentation: minor grammatical fixes in git-archive.txt.
2009-03-21 23:24:46 -07:00
David J. Mellor 4306bcb4e1 Documentation: reword example text in git-bisect.txt.
Avoid splitting sentences across examples of command usage.

Signed-off-by: David J. Mellor <dmellor@whistlingcat.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-03-20 09:34:44 -07:00
David J. Mellor ee9cf14d25 Documentation: reworded the "Description" section of git-bisect.txt.
Added fixes missing from 2364259.

Signed-off-by: David J. Mellor <dmellor@whistlingcat.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-03-19 01:38:35 -07:00
David J. Mellor 236425919b Documentation: reword the "Description" section of git-bisect.txt.
Reword this section to make it less chatty. Also make minor grammatical
fixes.

Signed-off-by: David J. Mellor <dmellor@whistlingcat.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-03-17 12:08:10 -07:00
John Tapsell fad5c96756 Documentation - More examples for git bisect
Including passing parameters to the programs, and running more
complicated checks without requiring a seperate shell script.

Signed-off-by: John Tapsell <johnflux@gmail.com>
Acked-by: Christian Couder <chriscool@tuxfamily.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-03-05 15:03:18 -08:00
Christian Couder 5413812f08 Documentation: describe how to "bisect skip" a range of commits
Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
2008-12-02 15:29:12 -08:00
Christian Couder 5bcce8494a Documentation: bisect: change a few instances of "git-cmd" to "git cmd"
Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-11-09 10:20:03 -08:00
Jonathan Nieder 42d36bb841 manpages: italicize gitk's name (where it was in teletype font)
The name `gitk` is sometimes meant to be entered at the command
prompt, but most uses are just referring to the program with that
name (not the incantation to start it).

Signed-off-by: Jonathan Nieder <jrnieder@uchicago.edu>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-07-05 11:24:40 -07:00
Jonathan Nieder ba020ef5eb manpages: italicize git command names (which were in teletype font)
The names of git commands are not meant to be entered at the
commandline; they are just names. So we render them in italics,
as is usual for command names in manpages.

Using

	doit () {
	  perl -e 'for (<>) { s/\`(git-[^\`.]*)\`/'\''\1'\''/g; print }'
	}
	for i in git*.txt config.txt diff*.txt blame*.txt fetch*.txt i18n.txt \
	        merge*.txt pretty*.txt pull*.txt rev*.txt urls*.txt
	do
	  doit <"$i" >"$i+" && mv "$i+" "$i"
	done
	git diff

.

Signed-off-by: Jonathan Nieder <jrnieder@uchicago.edu>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-07-05 11:24:40 -07:00
Jonathan Nieder 467c0197fd Documentation: more "git-" versus "git " changes
With git-commands moving out of $(bindir), it is useful to make a
clearer distinction between the git subcommand 'git-whatever' and
the command you type, `git whatever <options>`.  So we use a dash
after "git" when referring to the former and not the latter.

I already sent a patch doing this same thing, but I missed some
spots.

Signed-off-by: Jonathan Nieder <jrnieder@uchicago.edu>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-07-05 11:24:39 -07:00
Jonathan Nieder 483bc4f045 Documentation formatting and cleanup
Following what appears to be the predominant style, format
names of commands and commandlines both as `teletype text`.

While we're at it, add articles ("a" and "the") in some
places, italicize the name of the command in the manual page
synopsis line, and add a comma or two where it seems appropriate.

Signed-off-by: Jonathan Nieder <jrnieder@uchicago.edu>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-07-01 17:20:16 -07:00
Jonathan Nieder b1889c36d8 Documentation: be consistent about "git-" versus "git "
Since the git-* commands are not installed in $(bindir), using
"git-command <parameters>" in examples in the documentation is
not a good idea. On the other hand, it is nice to be able to
refer to each command using one hyphenated word. (There is no
escaping it, anyway: man page names cannot have spaces in them.)

This patch retains the dash in naming an operation, command,
program, process, or action. Complete command lines that can
be entered at a shell (i.e., without options omitted) are
made to use the dashless form.

The changes consist only of replacing some spaces with hyphens
and vice versa. After a "s/ /-/g", the unpatched and patched
versions are identical.

Signed-off-by: Jonathan Nieder <jrnieder@uchicago.edu>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-07-01 17:20:15 -07:00
Christian Couder 65e73dba4a documentation: bisect: remove bits talking about a bisection branch
... because we are now bisecting using a detached HEAD.

Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-06-14 10:52:57 -07:00
Christian Couder 9e1f0a85c6 documentation: move git(7) to git(1)
As the "git" man page describes the "git" command at the end-user
level, it seems better to move it to man section 1.

Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-06-06 11:18:28 -07:00
Junio C Hamano eafa29b7cb Merge branch 'gp/bisect-fix'
* gp/bisect-fix:
  bisect: print an error message when "git rev-list --bisect-vars" fails
  git-bisect.sh: don't accidentally override existing branch "bisect"
2008-05-12 15:44:43 -07:00
Christian Couder bac59f19b1 Documentation: bisect: add a few "git bisect run" examples
Before this patch, there were no "git bisect run" example.

Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-05-08 11:37:59 -07:00
Gerrit Pape ee831f7ddf git-bisect.sh: don't accidentally override existing branch "bisect"
If a branch named "bisect" or "new-bisect" already was created in the
repo by other means than git bisect, doing a git bisect used to override
the branch without a warning.  Now if the branch "bisect" or
"new-bisect" already exists, and it was not created by git bisect itself,
git bisect start fails with an appropriate error message.  Additionally,
if checking out a new bisect state fails due to a merge problem, git
bisect cleans up the temporary branch "new-bisect".

The accidental override has been noticed by Andres Salomon, reported
through
 http://bugs.debian.org/478647

Signed-off-by: Gerrit Pape <pape@smarden.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-05-05 17:18:20 -07:00
Christian Couder 243a60fbb5 bisect: add "git bisect help" subcommand to get a long usage string
Users are not often aware of the fact that "git bisect -h" can give
them a long usage description, as "git bisect" seems to accept only
dashless subcommands like "start", "good", ...

That's why this patch adds a "git bisect help" subcommand that just
calls "git bisect -h". This new subcommand is also fully documented
in the short usage string (that "git bisect" gives), in the long
usage string and in the man page (that "git help bisect" gives).

Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-04-11 23:03:50 -07:00
Dan McGee 5162e69732 Documentation: rename gitlink macro to linkgit
Between AsciiDoc 8.2.2 and 8.2.3, the following change was made to the stock
Asciidoc configuration:

@@ -149,7 +153,10 @@
 # Inline macros.
 # Backslash prefix required for escape processing.
 # (?s) re flag for line spanning.
-(?su)[\\]?(?P<name>\w(\w|-)*?):(?P<target>\S*?)(\[(?P<attrlist>.*?)\])=
+
+# Explicit so they can be nested.
+(?su)[\\]?(?P<name>(http|https|ftp|file|mailto|callto|image|link)):(?P<target>\S*?)(\[(?P<attrlist>.*?)\])=
+
 # Anchor: [[[id]]]. Bibliographic anchor.
 (?su)[\\]?\[\[\[(?P<attrlist>[\w][\w-]*?)\]\]\]=anchor3
 # Anchor: [[id,xreflabel]]

This default regex now matches explicit values, and unfortunately in this
case gitlink was being matched by just 'link', causing the wrong inline
macro template to be applied. By renaming the macro, we can avoid being
matched by the wrong regex.

Signed-off-by: Dan McGee <dpmcgee@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-01-06 18:41:44 -08:00
Junio C Hamano 235997c90f git-bisect visualize: work in non-windowed environments better
This teaches "git bisect visualize" to be more useful in non-windowed
environments.

 (1) When no option is given, and $DISPLAY is set, it continues to
     spawn gitk as before;

 (2) When no option is given, and $DISPLAY is unset, "git log" is run
     to show the range of commits between the bad one and the good ones;

 (3) If only "-flag" options are given, "git log <options>" is run.
     E.g. "git bisect visualize --stat"

 (4) Otherwise, all of the given options are taken as the initial part
     of the command line and the commit range expression is given to
     that command.  E.g. "git bisect visualize tig" will run "tig"
     history viewer to show between the bad one and the good ones.

As "visualize" is a bit too long to type, we also give it a shorter
synonym "view".

Signed-off-by: Junio C Hamano <gitster@pobox.com>
2007-12-08 02:58:26 -08:00
Christian Couder 71b0251cdd Bisect run: "skip" current commit if script exit code is 125.
This is incompatible with previous versions because an exit code
of 125 used to mark current commit as "bad". But hopefully this exit
code is not much used by test scripts or other programs. (126 and 127
are used by POSIX compliant shells to mean "found but not
executable" and "command not found", respectively.)

Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2007-10-26 23:27:24 -07:00
Christian Couder c39ce91827 Bisect: add "bisect skip" to the documentation.
Also fix "bisect bad" and "bisect good" short usage description.

Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2007-10-26 23:27:24 -07:00
Junio C Hamano a6080a0a44 War on whitespace
This uses "git-apply --whitespace=strip" to fix whitespace errors that have
crept in to our source files over time.  There are a few files that need
to have trailing whitespaces (most notably, test vectors).  The results
still passes the test, and build result in Documentation/ area is unchanged.

Signed-off-by: Junio C Hamano <gitster@pobox.com>
2007-06-07 00:04:01 -07:00
Christian Couder 6fe9c570cc Documentation: bisect: "start" accepts one bad and many good commits
Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2007-04-05 15:13:14 -07:00
Christian Couder 6cea055547 Documentation: bisect: make a comment fit better in the man page.
Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2007-03-23 23:29:29 -07:00
Christian Couder 1207f9e705 Documentation: bisect: add some titles to some paragraphs.
Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2007-03-23 23:29:09 -07:00
Christian Couder fed820ad56 Documentation: bisect: reformat more paragraphs.
Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2007-03-23 23:26:11 -07:00
Christian Couder cc070d1f79 Documentation: bisect: reword one paragraph.
Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2007-03-23 23:26:02 -07:00
Christian Couder 7891a2811d Documentation: bisect: reformat some paragraphs.
Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2007-03-23 23:25:54 -07:00
Christian Couder a17c410100 Bisect: implement "git bisect run <cmd>..." to automatically bisect.
This idea was suggested by Bill Lear
(Message-ID: <17920.38942.364466.642979@lisa.zopyra.com>)
and I think it is a very good one.

This patch adds a new test file for "git bisect run", but there
is currently only one basic test.

Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2007-03-23 01:54:47 -07:00
Junio C Hamano c3f0baacad Documentation: sync git.txt command list and manual page title
Also reorders a handful entries to make each list sorted
alphabetically.

Signed-off-by: Junio C Hamano <junkio@cox.net>
2007-01-18 15:53:37 -08:00
Junio C Hamano 556cb4e583 Documentation: talk about pathspec in bisect.
Also work-around asciidoc manpage trouble that does not seem to
allow more than one line in the SYNOPSIS section.

Signed-off-by: Junio C Hamano <junkio@cox.net>
2005-12-05 00:15:24 -08:00
Junio C Hamano d2abdd2647 documentation: git-bisect (help HTML break man)
Use the same trick Josef used to introduce line breaks for
git-mv documentation for now, to help HTML rendering.  This
breaks manpages and we need to come up with a better solution.

Noticed by linux@horizon.com (No Name).

Signed-off-by: Junio C Hamano <junkio@cox.net>
2005-12-02 12:20:34 -08:00
Christian Meder f73ae1fc5d Some typos and light editing of various manpages
Typos, light editing and clarifications.

Signed-off-by: Christian Meder <chris@absolutegiganten.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2005-10-05 15:08:26 -07:00
Jonas Fonseca df8baa42fe [PATCH] Random documentation fixes
The fixes focuses on improving the HTML output. Most noteworthy:

 - Fix the Makefile to also make various *.html files depend on
   included files.

 - Consistently use 'NOTE: ...' instead of '[ ... ]' for additional
   info.

 - Fix ending '::' for description lists in OPTION section etc.

 - Fix paragraphs in description lists ending up as preformated text.

 - Always use listingblocks (preformatted text wrapped in lines with -----)
   for examples that span empty lines, so they are put in only one HTML
   block.

 - Use '1.' instead of '(1)' for numbered lists.

 - Fix linking to other GIT docs.

 - git-rev-list.txt: put option descriptions in an OPTION section.

Signed-off-by: Jonas Fonseca <fonseca@diku.dk>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2005-10-03 13:23:47 -07:00
Sergey Vlasov a7154e916c [PATCH] Documentation: Update all files to use the new gitlink: macro
The replacement was performed automatically by these commands:

	perl -pi -e 's/link:(git.+)\.html\[\1\]/gitlink:$1\[1\]/g' \
		README Documentation/*.txt
	perl -pi -e 's/link:git\.html\[git\]/gitlink:git\[7\]/g' \
		README Documentation/*.txt

Signed-off-by: Sergey Vlasov <vsu@altlinux.ru>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2005-09-20 15:07:52 -07:00
Junio C Hamano b595ed1478 Add 'git bisect replay/log' documentation.
... lest I get yelled at by a very angry scm ;-).

Signed-off-by: Junio C Hamano <junkio@cox.net>
2005-09-10 15:23:09 -07:00
Junio C Hamano 215a7ad1ef Big tool rename.
As promised, this is the "big tool rename" patch.  The primary differences
since 0.99.6 are:

  (1) git-*-script are no more.  The commands installed do not
      have any such suffix so users do not have to remember if
      something is implemented as a shell script or not.

  (2) Many command names with 'cache' in them are renamed with
      'index' if that is what they mean.

There are backward compatibility symblic links so that you and
Porcelains can keep using the old names, but the backward
compatibility support  is expected to be removed in the near
future.

Signed-off-by: Junio C Hamano <junkio@cox.net>
2005-09-07 17:45:20 -07:00
Renamed from Documentation/git-bisect-script.txt (Browse further)