gitweb.git
Allow git commit --interactive with pathsConrad Irwin Sat, 7 May 2011 06:00:00 +0000 (23:00 -0700)

Allow git commit --interactive with paths

Make git commit --interactive feel more like git add --interactive by
allowing the user to restrict the list of files they have to deal with.

A test in t7501 used to ensure that this is not allowed; no need for that
anymore.

Signed-off-by: Conrad Irwin <conrad.irwin@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

t7501.8: feed a meaningful commandJeff King Mon, 9 May 2011 23:53:00 +0000 (16:53 -0700)

t7501.8: feed a meaningful command

The command expects "git commit --interactive <path>" to fail because you
cannot (yet) limit "commit --interactive" with a pathspec, but even if the
command allowed to take <path>, the test would have failed as saying just
7:quit would leave the index the same as the current commit, leading to an
attempt to create an empty commit that would fail without --allow-empty.

Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

git-p4: small improvements to user-preservationLuke Diamand Sat, 7 May 2011 10:19:43 +0000 (11:19 +0100)

git-p4: small improvements to user-preservation

. Slightly more paranoid checking of results from 'p4 change'
. Remove superfluous "-G"
. Don't modify the username if it is unchanged.
. Add a comment in the change template to show what is
going to be done.

Signed-off-by: Luke Diamand <luke@diamand.org>
Acked-By: Pete Wyckoff <pw@padd.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

Honor $(prefix) set in config.mak* when defining ETC_GIT*Johannes Sixt Mon, 9 May 2011 08:24:55 +0000 (10:24 +0200)

Honor $(prefix) set in config.mak* when defining ETC_GIT*

Notice that the prefix specified for the build influenced the definitions
of ETC_GITCONFIG and ETC_GITATTRIBUTES only when it was exactly '/usr'.
Kacper Kornet noticed that this was furthermore only the case when the
build was triggered using 'make prefix=/usr', i.e., the prefix was given
on the command line; it did not work when the prefix was specified in
config.mak because this file is included much later in the Makefile.

To fix this, move the conditional after the inclusion of config.mak.

Additionally, it is desirable to specify the etc directory for a build
(for example, a build with prefix /usr/local may still want to have the
system configuration in /etc/gitconfig). For this purpose, promote the
variable 'sysconfdir' from a helper variable to a configuration
variable. The prefix check that was moved must now be wrapped so that it
does not override sysconfdir setting given in config.mak.

Signed-off-by: Johannes Sixt <j6t@kdbg.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

Revert "Honor $(prefix) set in config.mak* when definin... Junio C Hamano Mon, 9 May 2011 22:12:13 +0000 (15:12 -0700)

Revert "Honor $(prefix) set in config.mak* when defining ETC_GIT* and sysconfdir"

This reverts commit 2910bf56a4ffc13c398fb04ba32910cb3b724091, as it
does not really solve the issue of making $(sysconfigdir) any more
useful than it currently is.

convert: make it harder to screw up adding a conversion... Junio C Hamano Mon, 9 May 2011 20:58:31 +0000 (13:58 -0700)

convert: make it harder to screw up adding a conversion attribute

The current internal API requires the callers of setup_convert_check() to
supply the git_attr_check structures (hence they need to know how many to
allocate), but they grab the same set of attributes for given path.

Define a new convert_attrs() API that fills a higher level information that
the callers (convert_to_git and convert_to_working_tree) really want, and
move the common code to interact with the attributes system to it.

Signed-off-by: Junio C Hamano <gitster@pobox.com>

convert: make it safer to add conversion attributesJunio C Hamano Mon, 9 May 2011 18:23:04 +0000 (11:23 -0700)

convert: make it safer to add conversion attributes

The places that need to pass an array of "struct git_attr_check" needed to
be careful to pass a large enough array and know what index each element
lied. Make it safer and easier to code these.

Besides, the hard-coded sequence of initializing various attributes was
too ugly after we gained more than a few attributes.

Signed-off-by: Junio C Hamano <gitster@pobox.com>

convert: give saner names to crlf/eol variables, types... Junio C Hamano Mon, 9 May 2011 20:12:57 +0000 (13:12 -0700)

convert: give saner names to crlf/eol variables, types and functions

Back when the conversion was only about the end-of-line convention, it
might have made sense to call what we do upon seeing CR/LF simply an
"action", but these days the conversion routines do a lot more than just
tweaking the line ending. Raname "action" to "crlf_action".

The function that decides what end of line conversion to use on the output
codepath was called "determine_output_conversion", as if there is no other
kind of output conversion. Rename it to "output_eol"; it is a function
that returns what EOL convention is to be used.

A function that decides what "crlf_action" needs to be used on the input
codepath, given what conversion attribute is set to the path and global
end-of-line convention, was called "determine_action". Rename it to
"input_crlf_action".

Signed-off-by: Junio C Hamano <gitster@pobox.com>

convert: rename the "eol" global variable to "core_eol"Junio C Hamano Mon, 9 May 2011 19:52:12 +0000 (12:52 -0700)

convert: rename the "eol" global variable to "core_eol"

Yes, it is clear that "eol" wants to mean some sort of end-of-line thing,
but as the name of a global variable, it is way too short to describe what
kind of end-of-line thing it wants to represent. Besides, there are many
codepaths that want to use their own local "char *eol" variable to point
at the end of the current line they are processing.

This global variable holds what we read from core.eol configuration
variable. Name it as such.

Signed-off-by: Junio C Hamano <gitster@pobox.com>

t1507: avoid "${parameter<op>'word'}" inside double... Junio C Hamano Mon, 9 May 2011 04:43:20 +0000 (21:43 -0700)

t1507: avoid "${parameter<op>'word'}" inside double-quotes

Kacper Kornet noticed that a $variable in "word" in the above construct is
not substituted by his pdksh. Modern POSIX compliant shells (e.g. dash,
ksh, bash) all seem to interpret POSIX "2.6.2 Parameter Expansion" that
says "word shall be subjected to tilde expansion, parameter expansion,
command substitution, and arithmetic expansion" in ${parameter<op>word},
to mean that the word is expanded as if it appeared in dq pairs, so if the
word were "'$variable'" (sans dq) it would expand to a single quote, the
value of the $variable and then a single quote.

Johannes Sixt reports that the behavior of quoting at the right of :- when
the ${...:-...} expansion appears in double-quotes was debated recently at
length at the Austin group. We can avoid this issue and future-proof the
test by a slight rewrite.

Helped-by: Johannes Sixt <j.sixt@viscovery.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

completion: move private shopt shim for zsh to __git_... Jonathan Nieder Wed, 27 Apr 2011 21:27:04 +0000 (16:27 -0500)

completion: move private shopt shim for zsh to __git_ namespace

Most zsh users probably probably do not expect a custom shopt function
to enter their environment just because they ran "source
~/.git-completion.sh".

Such namespace pollution makes development of other scripts confusing
(because it makes the bash-specific shopt utility seem to be available
in zsh) and makes git's tab completion script brittle (since any other
shell snippet implementing some other subset of shopt will break it).
Rename the shopt shim to the more innocuous __git_shopt to be a good
citizen (with two underscores to avoid confusion with completion rules
for a hypothetical "git shopt" command).

Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
Acked-by: SZEDER Gábor <szeder@ira.uka.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

t3701: add-p-fix makes the last test to passJunio C Hamano Sun, 8 May 2011 20:43:04 +0000 (13:43 -0700)

t3701: add-p-fix makes the last test to pass

Signed-off-by: Junio C Hamano <gitster@pobox.com>

rerere: libify rerere_clear() and rerere_gc()Junio C Hamano Sun, 8 May 2011 19:55:34 +0000 (12:55 -0700)

rerere: libify rerere_clear() and rerere_gc()

This moves the two features from builtin/rerere.c to a more library-ish
portion of the codebase. No behaviour change.

Signed-off-by: Junio C Hamano <gitster@pobox.com>

Use a temporary index for git commit --interactiveConrad Irwin Sat, 7 May 2011 05:59:59 +0000 (22:59 -0700)

Use a temporary index for git commit --interactive

Change the behaviour of git commit --interactive so that when you abort
the commit (by leaving the commit message empty) the index remains
unchanged.

Hitherto an aborted commit --interactive has added the selected hunks to
the index regardless of whether the commit succeeded or not.

Signed-off-by: Conrad Irwin <conrad.irwin@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

Remove gitweb/gitweb.cgi and other legacy targets from... Jakub Narebski Sat, 7 May 2011 12:45:21 +0000 (14:45 +0200)

Remove gitweb/gitweb.cgi and other legacy targets from main Makefile

Now that there is gitweb/Makefile, let's leave only "gitweb" and
"install-gitweb" targets in main Makefile. Those targets just
delegate to gitweb's Makefile.

Requested-by: Junio C Hamano <gitster@pobox.com>
Signed-off-by: Jakub Narebski <jnareb@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

git-instaweb: Simplify build dependency on gitwebJakub Narebski Sat, 7 May 2011 12:45:20 +0000 (14:45 +0200)

git-instaweb: Simplify build dependency on gitweb

Since c0cb4ed (git-instaweb: Configure it to work with new gitweb
structure, 2010-05-28) git-instaweb does not re-create gitweb.cgi
etc., but makes use of installed gitweb. Therefore simplify
git-instaweb dependency on gitweb subsystem in main Makefile from
'gitweb/gitweb.cgi gitweb/static/gitweb.css gitweb/static/gitweb.js'
to simply 'gitweb'.

This is preparation for splitting gitweb.perl script, and for
splitting gitweb.js (to be reassembled / combined on build). This way
we don't have to duplicate parts of gitweb/Makefile in main
Makefile... it is also more correct description of git-instaweb
dependency.

Reported-by: Junio C Hamano <gitster@pobox.com>
Signed-off-by: Jakub Narebski <jnareb@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

tests: check git does not barf on merge.ff values for... Jonathan Nieder Fri, 6 May 2011 21:59:47 +0000 (16:59 -0500)

tests: check git does not barf on merge.ff values for future versions of git

Maybe some day in the future we will want to support a syntax
like

[merge]
ff = branch1
ff = branch2
ff = branch3

in addition to the currently permitted "true", "false", and "only"
values. So make sure we continue to treat such configurations as
though an unknown variable had been defined rather than erroring out,
until it is time to implement such a thing, so configuration files
using such a facility can be shared between present and future git.

While at it, add a few missing && and start the "combining --squash
and --no-ff" test with a known state so we can be sure it does not
succeed or fail for the wrong reason.

Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

tests: teach verify_parents to check for extra parentsJonathan Nieder Fri, 6 May 2011 21:00:21 +0000 (16:00 -0500)

tests: teach verify_parents to check for extra parents

Currently verify_parents only makes sure that the earlier parents of
HEAD match the commits given, and does not care if there are more
parents. This makes it harder than one would like to check that, for
example, parent reduction works correctly when making an octopus.

Fix it by checking that HEAD^(n+1) is not a valid commit name.
Noticed while working on a new test that was supposed to create a
fast-forward one commit ahead but actually created a merge.

Reported-by: Junio C Hamano <gitster@pobox.com>
Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

merge: introduce merge.ff configuration variableJunio C Hamano Fri, 6 May 2011 19:27:05 +0000 (12:27 -0700)

merge: introduce merge.ff configuration variable

This variable gives the default setting for --ff, --no-ff or --ff-only
options of "git merge" command.

Signed-off-by: Junio C Hamano <gitster@pobox.com>

Merge branch 'jc/maint-branch-mergeoptions' into mg... Junio C Hamano Fri, 6 May 2011 22:03:25 +0000 (15:03 -0700)

Merge branch 'jc/maint-branch-mergeoptions' into mg/merge-ff-config

* jc/maint-branch-mergeoptions:
merge: make branch.<name>.mergeoptions correctly override merge.<option>

merge: make branch.<name>.mergeoptions correctly overri... Junio C Hamano Thu, 5 May 2011 00:42:51 +0000 (17:42 -0700)

merge: make branch.<name>.mergeoptions correctly override merge.<option>

The parsing of the additional command line parameters supplied to
the branch.<name>.mergeoptions configuration variable was implemented
at the wrong stage. If any merge-related variable came after we read
branch.<name>.mergeoptions, the earlier value was overwritten.

We should first read all the merge.* configuration, override them by
reading from branch.<name>.mergeoptions and then finally read from
the command line.

This patch should fix it, even though I now strongly suspect that
branch.<name>.mergeoptions that gives a single command line that
needs to be parsed was likely to be an ill-conceived idea to begin
with. Sigh...

Helped-by: Jonathan Nieder <jrnieder@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

tests: eliminate unnecessary setup test assertionsJonathan Nieder Fri, 6 May 2011 20:58:52 +0000 (15:58 -0500)

tests: eliminate unnecessary setup test assertions

Most of git's tests write files and define shell functions and
variables that will last throughout a test script at the top of
the script, before all test assertions:

. ./test-lib.sh

VAR='some value'
export VAR

>empty

fn () {
do something
}

test_expect_success 'setup' '
... nontrivial commands go here ...
'

Two scripts use a different style with this kind of trivial code
enclosed by a test assertion; fix them. The usual style is easier to
read since there is less indentation to keep track of and no need to
worry about nested quotes; and on the other hand, because the commands
in question are trivial, it should not make the test suite any worse
at catching future bugs in git.

While at it, make some other small tweaks:

- spell function definitions with a space before () for consistency
with other scripts;

- use the self-contained command "git mktree </dev/null" in
preference to "git write-tree" which looks at the index when
writing an empty tree.

Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

Update draft release notes to 1.7.6Junio C Hamano Fri, 6 May 2011 18:13:08 +0000 (11:13 -0700)

Update draft release notes to 1.7.6

Signed-off-by: Junio C Hamano <gitster@pobox.com>

Merge branch 'jn/run-command-error-failure'Junio C Hamano Fri, 6 May 2011 18:01:04 +0000 (11:01 -0700)

Merge branch 'jn/run-command-error-failure'

* jn/run-command-error-failure:
run-command: handle short writes and EINTR in die_child
tests: check error message from run_command

Merge branch 'js/info-man-path'Junio C Hamano Fri, 6 May 2011 18:00:46 +0000 (11:00 -0700)

Merge branch 'js/info-man-path'

* js/info-man-path:
Documentation: clarify meaning of --html-path, --man-path, and --info-path
git: add --info-path and --man-path options

Conflicts:
Makefile

Merge branch 'im/hashcmp-optim'Junio C Hamano Fri, 6 May 2011 18:00:36 +0000 (11:00 -0700)

Merge branch 'im/hashcmp-optim'

* im/hashcmp-optim:
hashcmp(): inline memcmp() by hand to optimize

Merge branch 'jk/merge-one-file-working-tree'Junio C Hamano Fri, 6 May 2011 17:54:08 +0000 (10:54 -0700)

Merge branch 'jk/merge-one-file-working-tree'

* jk/merge-one-file-working-tree:
merge-one-file: fix broken merges with alternate work trees
add tests for merge-index / merge-one-file

Merge branch 'jc/fix-diff-files-unmerged'Junio C Hamano Fri, 6 May 2011 17:52:58 +0000 (10:52 -0700)

Merge branch 'jc/fix-diff-files-unmerged'

* jc/fix-diff-files-unmerged:
diff-files: show unmerged entries correctly
diff: remove often unused parameters from diff_unmerge()
diff.c: return filepair from diff_unmerge()
test: use $_z40 from test-lib

Merge branch 'cj/p4merge'Junio C Hamano Fri, 6 May 2011 17:52:16 +0000 (10:52 -0700)

Merge branch 'cj/p4merge'

* cj/p4merge:
Pass empty file to p4merge where no base is suitable.

Merge branch 'gr/cvsimport-alternative-cvspass-location'Junio C Hamano Fri, 6 May 2011 17:52:12 +0000 (10:52 -0700)

Merge branch 'gr/cvsimport-alternative-cvspass-location'

* gr/cvsimport-alternative-cvspass-location:
Look for password in both CVS and CVSNT password files.

Merge branch 'sg/completion-cleanup'Junio C Hamano Fri, 6 May 2011 17:52:03 +0000 (10:52 -0700)

Merge branch 'sg/completion-cleanup'

* sg/completion-cleanup:
completion: remove unnecessary _get_comp_words_by_ref() invocations
completion: don't modify the $cur variable in completion functions

Merge branch 'js/blame-parsename'Junio C Hamano Fri, 6 May 2011 17:50:32 +0000 (10:50 -0700)

Merge branch 'js/blame-parsename'

* js/blame-parsename:
t/annotate-tests: Use echo & cat instead of sed
blame: tolerate bogus e-mail addresses a bit better

Merge branch 'jk/format-patch-quote-special-in-from'Junio C Hamano Fri, 6 May 2011 17:50:18 +0000 (10:50 -0700)

Merge branch 'jk/format-patch-quote-special-in-from'

* jk/format-patch-quote-special-in-from:
pretty: quote rfc822 specials in email addresses

Conflicts:
pretty.c
t/t4014-format-patch.sh

Merge branch 'nd/struct-pathspec'Junio C Hamano Fri, 6 May 2011 17:50:06 +0000 (10:50 -0700)

Merge branch 'nd/struct-pathspec'

* nd/struct-pathspec:
pathspec: rename per-item field has_wildcard to use_wildcard
Improve tree_entry_interesting() handling code
Convert read_tree{,_recursive} to support struct pathspec
Reimplement read_tree_recursive() using tree_entry_interesting()

Merge branch 'aw/maint-rebase-i-p-no-ff'Junio C Hamano Fri, 6 May 2011 17:50:00 +0000 (10:50 -0700)

Merge branch 'aw/maint-rebase-i-p-no-ff'

* aw/maint-rebase-i-p-no-ff:
git-rebase--interactive.sh: preserve-merges fails on merges created with no-ff

Conflicts:
git-rebase--interactive.sh

Merge branch 'mg/alias-expose-prefix'Junio C Hamano Fri, 6 May 2011 17:49:57 +0000 (10:49 -0700)

Merge branch 'mg/alias-expose-prefix'

* mg/alias-expose-prefix:
handle_alias: provide GIT_PREFIX to !alias
t1020: test !alias in subdirectory

Merge branch 'mg/diff-uiconfig-doc'Junio C Hamano Fri, 6 May 2011 17:49:53 +0000 (10:49 -0700)

Merge branch 'mg/diff-uiconfig-doc'

* mg/diff-uiconfig-doc:
config.txt,diff-options.txt: porcelain vs. plumbing for color.diff

Merge branch 'maint'Junio C Hamano Fri, 6 May 2011 17:44:23 +0000 (10:44 -0700)

Merge branch 'maint'

* maint:
Remove duplicated "is a"

Remove duplicated "is a"João Britto Fri, 6 May 2011 04:16:17 +0000 (01:16 -0300)

Remove duplicated "is a"

Signed-off-by: João Britto <jabcalves@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

fast-import: fix option parser for no-arg optionsSverre Rabbelier Thu, 5 May 2011 18:56:00 +0000 (20:56 +0200)

fast-import: fix option parser for no-arg options

While refactoring the options parser in bc3c79a (fast-import: add
(non-)relative-marks feature, 2009-12-04), it was made too lenient
for options that take no argument, fix that.

Signed-off-by: Sverre Rabbelier <srabbelier@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

Merge branch 'maint'Junio C Hamano Thu, 5 May 2011 21:43:45 +0000 (14:43 -0700)

Merge branch 'maint'

* maint:
t3701: fix here document
git-fast-import.txt: --relative-marks takes no parameter
shell: add missing initialization of argv0_path

Merge branch 'js/maint-1.6.6-send-pack-stateless-rpc... Junio C Hamano Thu, 5 May 2011 20:46:36 +0000 (13:46 -0700)

Merge branch 'js/maint-1.6.6-send-pack-stateless-rpc-deadlock-fix' into js/maint-send-pack-stateless-rpc-deadlock-fix

* js/maint-1.6.6-send-pack-stateless-rpc-deadlock-fix:
send-pack: unbreak push over stateless rpc

send-pack: unbreak push over stateless rpcJeff King Thu, 5 May 2011 06:18:45 +0000 (02:18 -0400)

send-pack: unbreak push over stateless rpc

Commit 09c9957 (send-pack: avoid deadlock when pack-object
dies early, 2011-04-25) attempted to fix a hang in the
stateless rpc case by closing a file descriptor early, but
we still need that descriptor.

Basically the deadlock can happen when pack-objects fails,
and the descriptor to upstream is left open. We never send
the pack, so the upstream is left waiting for us to say
something, and we are left waiting for upstream to close the
connection.

In the non-rpc case, our descriptor points straight to the
upstream. We hand it off to run-command, which takes
ownership and closes the descriptor after pack-objects
finishes (whether it succeeds or not).

Commit 09c9957 tried to emulate that in the rpc case. That
isn't right, though. We actually have a descriptor going
back to the remote-helper, and we need to keep using it
after pack-objects is finished. Closing it early completely
breaks pushing via smart-http.

We still need to do something on error to signal the
remote-helper that we won't be sending any pack data
(otherwise we get the deadlock). In an ideal world, we
would send a special packet back that says "Sorry, there was
an error". But the remote-helper doesn't understand any such
packet, so the best we can do is close the descriptor and
let it report that we hung up unexpectedly.

Signed-off-by: Jeff King <peff@peff.net>
Acked-by: Johannes Sixt <j6t@kdbg.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

git-reset.txt: better docs for '--patch'Valentin Haenel Thu, 5 May 2011 19:58:18 +0000 (21:58 +0200)

git-reset.txt: better docs for '--patch'

Describe '-p' as a short form of '--patch' in synopsis. Also include a better
explanation of this option and additionally refer the reader to the patch mode
description of git-add documentation.

Helped-by: Jeff King <peff@peff.net>
Mentored-by: Junio C Hamano <gitster@pobox.com>
Signed-off-by: Valentin Haenel <valentin.haenel@gmx.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

git-checkout.txt: better docs for '--patch'Valentin Haenel Thu, 5 May 2011 18:48:48 +0000 (20:48 +0200)

git-checkout.txt: better docs for '--patch'

Describe '-p' as a short form of '--patch' in synopsis and options. Also
refer the reader to the patch mode description of git-add documentation.

Helped-by: Jeff King <peff@peff.net>
Mentored-by: Junio C Hamano <gitster@pobox.com>
Signed-off-by: Valentin Haenel <valentin.haenel@gmx.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

git-stash.txt: better docs for '--patch'Valentin Haenel Thu, 5 May 2011 18:48:47 +0000 (20:48 +0200)

git-stash.txt: better docs for '--patch'

Describe '-p' as a short form of '--patch' in synopsis and options. Also
refer the reader to the patch mode description of git-add documentation.

Helped-by: Jeff King <peff@peff.net>
Mentored-by: Junio C Hamano <gitster@pobox.com>
Signed-off-by: Valentin Haenel <valentin.haenel@gmx.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

git-add.txt: document 'interactive.singlekey'Valentin Haenel Thu, 5 May 2011 18:48:45 +0000 (20:48 +0200)

git-add.txt: document 'interactive.singlekey'

This is documented in the section about the 'Interactive Mode', rather than for
the option '--patch', since this is the section is where people go to learn
about '--patch'.

Helped-by: Jeff King <peff@peff.net>
Mentored-by: Junio C Hamano <gitster@pobox.com>
Signed-off-by: Valentin Haenel <valentin.haenel@gmx.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

config.txt: 'interactive.singlekey; is used by...Valentin Haenel Mon, 2 May 2011 13:44:28 +0000 (15:44 +0200)

config.txt: 'interactive.singlekey; is used by...

The config variable 'interactive.singlekey' influences also '--patch' mode of
git-add, git-reset, and git-checkout.

Helped-by: Jeff King <peff@peff.net>
Signed-off-by: Valentin Haenel <valentin.haenel@gmx.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

t3701: fix here documentJunio C Hamano Thu, 5 May 2011 18:28:52 +0000 (11:28 -0700)

t3701: fix here document

A broken here-document was not caught because end of file is taken by
an implicit end of the here document (POSIX does not seem to say it is
an error to lack the delimiter), and everything in the test just turned
into a single "cat into a file".

Noticed-by: Kacper Kornet <draenog@pld-linux.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

git-fast-import.txt: --relative-marks takes no parameterMichael J Gruber Thu, 5 May 2011 09:13:38 +0000 (11:13 +0200)

git-fast-import.txt: --relative-marks takes no parameter

Remove spurious "=" after --relative-marks.

Signed-off-by: Michael J Gruber <git@drmicha.warpmail.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

shell: add missing initialization of argv0_pathDima Sharov Thu, 5 May 2011 06:40:17 +0000 (09:40 +0300)

shell: add missing initialization of argv0_path

According to c6dfb39 (remote-curl: add missing initialization of
argv0_path, 2009-10-13), stand-alone programs (non-builtins)
must call git_extract_argv0_path(argv[0]) in order to help builds
that derive the installation prefix at runtime. Without this call,
the program segfaults (or raises an assertion failure).

Signed-off-by: Dima Sharov <git.avalakvista@gmail.com>
Acked-by: Johannes Sixt <j6t@kdbg.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

t/annotate-tests: Use echo & cat instead of sedBrian Gernhardt Thu, 5 May 2011 04:43:37 +0000 (00:43 -0400)

t/annotate-tests: Use echo & cat instead of sed

The use of the sed command "1i No robots allowed" caused the version
of sed in OS X to die with

sed: 1: "1i "No robots allowed"\n": command i expects \ followed by
text

Since this command was just trying to add a single line to the
beginning of the file, do the same with "echo" followed by "cat".

Unbreaks t8001 and t8002 on OS X 10.6.7

Signed-off-by: Brian Gernhardt <brian@gernhardtsoftware.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

Update draft release notes to 1.7.6Junio C Hamano Wed, 4 May 2011 23:02:17 +0000 (16:02 -0700)

Update draft release notes to 1.7.6

Signed-off-by: Junio C Hamano <gitster@pobox.com>

Merge branch 'ml/test-readme'Junio C Hamano Wed, 4 May 2011 22:52:00 +0000 (15:52 -0700)

Merge branch 'ml/test-readme'

* ml/test-readme:
t/README: unify documentation of test function args

Merge branch 'ft/gitweb-tar-with-gzip-n'Junio C Hamano Wed, 4 May 2011 22:51:57 +0000 (15:51 -0700)

Merge branch 'ft/gitweb-tar-with-gzip-n'

* ft/gitweb-tar-with-gzip-n:
gitweb: supply '-n' to gzip for identical output

Merge branch 'mg/rev-list-count-cherry'Junio C Hamano Wed, 4 May 2011 22:51:53 +0000 (15:51 -0700)

Merge branch 'mg/rev-list-count-cherry'

* mg/rev-list-count-cherry:
rev-list --count: separate count for --cherry-mark

Merge branch 'ss/doc-svn'Junio C Hamano Wed, 4 May 2011 22:51:43 +0000 (15:51 -0700)

Merge branch 'ss/doc-svn'

* ss/doc-svn:
remove noise and inaccuracies from git-svn docs

Merge branch 'jn/format-patch-doc'Junio C Hamano Wed, 4 May 2011 22:51:41 +0000 (15:51 -0700)

Merge branch 'jn/format-patch-doc'

* jn/format-patch-doc:
Documentation/format-patch: suggest Toggle Word Wrap add-on for Thunderbird
Documentation: publicize hints for sending patches with GMail
Documentation: publicize KMail hints for sending patches inline
Documentation: hints for sending patches inline with Thunderbird
Documentation: explain how to check for patch corruption

Merge branch 'vr/merge-base-doc'Junio C Hamano Wed, 4 May 2011 22:51:37 +0000 (15:51 -0700)

Merge branch 'vr/merge-base-doc'

* vr/merge-base-doc:
Restructure documentation for git-merge-base.
Documentation: update to git-merge-base --octopus

Merge branch 'ss/cherry-pick-x-doc'Junio C Hamano Wed, 4 May 2011 22:51:35 +0000 (15:51 -0700)

Merge branch 'ss/cherry-pick-x-doc'

* ss/cherry-pick-x-doc:
doc: Clarify that "cherry-pick -x" does not use "git notes"

Merge branch 'jn/maint-format-patch-doc'Junio C Hamano Wed, 4 May 2011 22:51:31 +0000 (15:51 -0700)

Merge branch 'jn/maint-format-patch-doc'

* jn/maint-format-patch-doc:
Documentation: describe the format of messages with inline patches

Merge branch 'jk/format-patch-multiline-header'Junio C Hamano Wed, 4 May 2011 22:51:27 +0000 (15:51 -0700)

Merge branch 'jk/format-patch-multiline-header'

* jk/format-patch-multiline-header:
format-patch: wrap email addresses after long names

Merge branch 'jm/mergetool-submodules'Junio C Hamano Wed, 4 May 2011 22:51:23 +0000 (15:51 -0700)

Merge branch 'jm/mergetool-submodules'

* jm/mergetool-submodules:
mergetool: Teach about submodules

Sync with 1.7.5.1Junio C Hamano Wed, 4 May 2011 22:49:04 +0000 (15:49 -0700)

Sync with 1.7.5.1

Signed-off-by: Junio C Hamano <gitster@pobox.com>

Git 1.7.5.1 v1.7.5.1Junio C Hamano Wed, 4 May 2011 22:47:40 +0000 (15:47 -0700)

Git 1.7.5.1

Signed-off-by: Junio C Hamano <gitster@pobox.com>

Merge branch 'jh/dirstat' into maintJunio C Hamano Wed, 4 May 2011 21:59:07 +0000 (14:59 -0700)

Merge branch 'jh/dirstat' into maint

* jh/dirstat:
--dirstat: In case of renames, use target filename instead of source filename
Teach --dirstat not to completely ignore rearranged lines within a file
--dirstat-by-file: Make it faster and more correct
--dirstat: Describe non-obvious differences relative to --stat or regular diff

Merge branch 'sp/maint-clear-postfields' into maintJunio C Hamano Wed, 4 May 2011 21:58:56 +0000 (14:58 -0700)

Merge branch 'sp/maint-clear-postfields' into maint

* sp/maint-clear-postfields:
http: clear POSTFIELDS when initializing a slot

Merge branch 'jk/maint-stash-oob' into maintJunio C Hamano Wed, 4 May 2011 21:58:42 +0000 (14:58 -0700)

Merge branch 'jk/maint-stash-oob' into maint

* jk/maint-stash-oob:
stash: fix false positive in the invalid ref test.
stash: fix accidental apply of non-existent stashes

Conflicts:
t/t3903-stash.sh

Merge branch 'jk/maint-upload-pack-shallow' into maintJunio C Hamano Wed, 4 May 2011 21:58:13 +0000 (14:58 -0700)

Merge branch 'jk/maint-upload-pack-shallow' into maint

* jk/maint-upload-pack-shallow:
upload-pack: start pack-objects before async rev-list

Merge branch 'dm/stash-k-i-p' into maintJunio C Hamano Wed, 4 May 2011 21:57:49 +0000 (14:57 -0700)

Merge branch 'dm/stash-k-i-p' into maint

* dm/stash-k-i-p:
stash: ensure --no-keep-index and --patch can be used in any order
stash: add two more tests for --no-keep-index

Merge branch 'jc/pack-objects-bigfile' into maintJunio C Hamano Wed, 4 May 2011 21:57:38 +0000 (14:57 -0700)

Merge branch 'jc/pack-objects-bigfile' into maint

* jc/pack-objects-bigfile:
Teach core.bigfilethreashold to pack-objects

Merge branch 'mg/reflog-with-options' into maintJunio C Hamano Wed, 4 May 2011 21:57:33 +0000 (14:57 -0700)

Merge branch 'mg/reflog-with-options' into maint

* mg/reflog-with-options:
reflog: fix overriding of command line options
t/t1411: test reflog with formats
builtin/log.c: separate default and setup of cmd_log_init()

Merge branch 'jk/stash-loosen-safety' into maintJunio C Hamano Wed, 4 May 2011 21:57:15 +0000 (14:57 -0700)

Merge branch 'jk/stash-loosen-safety' into maint

* jk/stash-loosen-safety:
stash: drop dirty worktree check on apply

Merge branch 'ar/clean-rmdir-empty' into maintJunio C Hamano Wed, 4 May 2011 21:57:06 +0000 (14:57 -0700)

Merge branch 'ar/clean-rmdir-empty' into maint

* ar/clean-rmdir-empty:
clean: unreadable directory may still be rmdir-able if it is empty

Merge branch 'mg/sha1-path-advise' into maintJunio C Hamano Wed, 4 May 2011 21:56:51 +0000 (14:56 -0700)

Merge branch 'mg/sha1-path-advise' into maint

* mg/sha1-path-advise:
sha1_name: Suggest commit:./file for path in subdir
t1506: factor out test for "Did you mean..."

git-add.txt: document 'add.ignoreErrors'Valentin Haenel Wed, 4 May 2011 19:58:17 +0000 (21:58 +0200)

git-add.txt: document 'add.ignoreErrors'

Signed-off-by: Valentin Haenel <valentin.haenel@gmx.de>
Noticed-by: Junio C Hamano <gitster@pobox.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

t5541-http-push: add test for chunkedTay Ray Chuan Wed, 4 May 2011 17:19:50 +0000 (01:19 +0800)

t5541-http-push: add test for chunked

Trigger the chunked type of pushing for smart HTTP. This can serve as a
regression test for the issue fixed in 1e41827 (http: clear POSTFIELDS
when initializing a slot).

Signed-off-by: Tay Ray Chuan <rctay89@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

http-push: refactor curl_easy_setup madnessDan McGee Tue, 3 May 2011 15:47:29 +0000 (23:47 +0800)

http-push: refactor curl_easy_setup madness

We were doing (nearly) the same thing all over the place, in slightly
different orders, different variable names, etc. Refactor most calls
into two helper functions, one for GET and one for everything else, that
do the heavy lifting leaving most callsites a lot cleaner in the
process.

Note that the setting of CURLOPT_PUT at the callsites of
curl_setup_http() which previously didn't do it (eg.
locking_available(), remote_ls()) is safe, since that
option is deprecated in libcurl in place of, and has the same effect as,
CURLOPT_UPLOAD.

Signed-off-by: Dan McGee <dpmcgee@gmail.com>
Signed-off-by: Tay Ray Chuan <rctay89@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

http-push: use const for strings in signaturesDan McGee Tue, 3 May 2011 15:47:28 +0000 (23:47 +0800)

http-push: use const for strings in signatures

Signed-off-by: Dan McGee <dpmcgee@gmail.com>
Signed-off-by: Tay Ray Chuan <rctay89@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

http: make curl callbacks match contracts from curl... Dan McGee Tue, 3 May 2011 15:47:27 +0000 (23:47 +0800)

http: make curl callbacks match contracts from curl header

Yes, these don't match perfectly with the void* first parameter of the
fread/fwrite in the standard library, but they do match the curl
expected method signature. This is needed when a refactor passes a
curl_write_callback around, which would otherwise give incorrect
parameter warnings.

Signed-off-by: Dan McGee <dpmcgee@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

Update draft release notes to 1.7.6Junio C Hamano Mon, 2 May 2011 23:10:50 +0000 (16:10 -0700)

Update draft release notes to 1.7.6

Signed-off-by: Junio C Hamano <gitster@pobox.com>

Merge branch 'jk/notes-ui-updates'Junio C Hamano Mon, 2 May 2011 22:58:50 +0000 (15:58 -0700)

Merge branch 'jk/notes-ui-updates'

* jk/notes-ui-updates:
contrib/completion: --notes, --no-notes
log/pretty-options: Document --[no-]notes and deprecate old notes options
revision.c: make --no-notes reset --notes list
revision.c: support --notes command-line option
notes: refactor display notes default handling
notes: refactor display notes extra refs field
revision.c: refactor notes ref expansion
notes: make expand_notes_ref globally accessible

Merge branch 'ab/i18n-fixup'Junio C Hamano Mon, 2 May 2011 22:58:40 +0000 (15:58 -0700)

Merge branch 'ab/i18n-fixup'

* ab/i18n-fixup: (24 commits)
i18n: use test_i18n{cmp,grep} in t7600, t7607, t7611 and t7811
i18n: use test_i18n{grep,cmp} in t7508
i18n: use test_i18ngrep in t7506
i18n: use test_i18ngrep and test_i18ncmp in t7502
i18n: use test_i18ngrep in t7501
i18n: use test_i18ncmp in t7500
i18n: use test_i18ngrep in t7201
i18n: use test_i18ncmp and test_i18ngrep in t7102 and t7110
i18n: use test_i18ncmp and test_i18ngrep in t5541, t6040, t6120, t7004, t7012 and t7060
i18n: use test_i18ncmp and test_i18ngrep in t3700, t4001 and t4014
i18n: use test_i18ncmp and test_i18ngrep in t3203, t3501 and t3507
i18n: use test_i18ngrep in t2020, t2204, t3030, and t3200
i18n: use test_i18ngrep in lib-httpd and t2019
i18n: do not overuse C_LOCALE_OUTPUT (grep)
i18n: use test_i18ncmp in t1200 and t2200
i18n: .git file is not a human readable message (t5601)
i18n: do not overuse C_LOCALE_OUTPUT
i18n: mark init-db messages for translation
i18n: mark checkout plural warning for translation
i18n: mark checkout --detach messages for translation
...

Merge branch 'nm/submodule-update-force'Junio C Hamano Mon, 2 May 2011 22:58:36 +0000 (15:58 -0700)

Merge branch 'nm/submodule-update-force'

* nm/submodule-update-force:
submodule: Add --force option for git submodule update

Conflicts:
t/t7406-submodule-update.sh

Merge branch 'jh/notes-add-ui'Junio C Hamano Mon, 2 May 2011 22:58:32 +0000 (15:58 -0700)

Merge branch 'jh/notes-add-ui'

* jh/notes-add-ui:
Make "git notes add" more user-friendly when there are existing notes

Conflicts:
builtin/notes.c

Merge branch 'nd/maint-setup'Junio C Hamano Mon, 2 May 2011 22:58:30 +0000 (15:58 -0700)

Merge branch 'nd/maint-setup'

* nd/maint-setup:
Kill off get_relative_cwd()
setup: return correct prefix if worktree is '/'

Conflicts:
dir.c
setup.c

Merge branch 'mz/maint-rename-unmerged'Junio C Hamano Mon, 2 May 2011 22:58:27 +0000 (15:58 -0700)

Merge branch 'mz/maint-rename-unmerged'

* mz/maint-rename-unmerged:
diffcore-rename: don't consider unmerged path as source

Documentation: clarify meaning of --html-path, --man... Jonathan Nieder Mon, 2 May 2011 06:07:45 +0000 (01:07 -0500)

Documentation: clarify meaning of --html-path, --man-path, and --info-path

These options tell UI programs where git put its documentation, so
"Help" actions can show the documentation for *this* version of git
without regard to how MANPATH and INFOPATH are set up. Details:

. Each variable tells where documentation is expected to be. They do
not indicate whether documentation was actually installed.

. The output of "git --html-path" is an absolute path and can be used
in "file://$(git --html-path)/git-add.html" to name the HTML file
documenting a particular command.

. --man-path names a manual page hierarchy (e.g.,
/home/user/share/man). Its output can be passed to "man -M" or put
at the beginning of $MANPATH.

. --info-path names a directory with info files (e.g.,
/home/user/share/info). Its output is suitable as an argument to
"info -d" or for inclusion in $INFOPATH.

Helped-by: Junio C Hamano <gitster@pobox.com>
Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

git: add --info-path and --man-path optionsJon Seymour Sun, 1 May 2011 08:16:25 +0000 (18:16 +1000)

git: add --info-path and --man-path options

Similar to the way the --html-path option lets UI programs learn where git
has its HTML documentation pages, expose the other two paths used to store
the documentation pages of these two types.

Signed-off-by: Jon Seymour <jon.seymour@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

Update draft release notes to 1.7.6Junio C Hamano Sun, 1 May 2011 23:29:43 +0000 (16:29 -0700)

Update draft release notes to 1.7.6

Signed-off-by: Junio C Hamano <gitster@pobox.com>

Merge branch 'rs/strbuf-setlen-assert'Junio C Hamano Sun, 1 May 2011 23:25:04 +0000 (16:25 -0700)

Merge branch 'rs/strbuf-setlen-assert'

* rs/strbuf-setlen-assert:
strbuf: clarify assertion in strbuf_setlen()

Merge branch 'vh/git-svn-doc'Junio C Hamano Sun, 1 May 2011 23:25:01 +0000 (16:25 -0700)

Merge branch 'vh/git-svn-doc'

* vh/git-svn-doc:
git-svn.txt: small typeface improvements
git-svn.txt: move option descriptions
git-svn.txt: fix usage of --add-author-from

Pass empty file to p4merge where no base is suitable.Ciaran Jessup Sun, 1 May 2011 22:16:02 +0000 (23:16 +0100)

Pass empty file to p4merge where no base is suitable.

Modify the p4merge client command to pass a reference to an empty file
instead of the local file when no base revision available.

In the situation where a merge tries to add a file from one branch
into a branch that already contains that file (by name), p4merge
currently seems to have successfully automatically resolved the
'conflict' when it is opened (correctly if the files differed by
just whitespace for example) but leaves the save button disabled. This
means the user of the p4merge client cannot commit the resolved
changes back to disk and merely exits, leaving the original
(merge-conflicted) file intact on the disk.

Provide an empty base file to p4merge so that it leaves the save
button enabled. This will allow saving of the auto-resolution to
disk.

Signed-off-by: Ciaran Jessup <ciaranj@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

Look for password in both CVS and CVSNT password files.Guy Rouillier Sun, 1 May 2011 05:33:52 +0000 (01:33 -0400)

Look for password in both CVS and CVSNT password files.

In conn, if password is not passed on command line, look for a password
entry in both the CVS password file and the CVSNT password file. If only
one file is found and the requested repository is in that file, or if both
files are found but the requested repository is found in only one file, use
the password from the single file containing the repository entry. If both
files are found and the requested repository is found in both files, then
produce an error message.

The CVS password file separates tokens with a space character, while
the CVSNT password file separates tokens with an equal (=) character.
Add a sub find_password_entry that accepts the password file name
and a delimiter to eliminate code duplication.

Signed-off-by: Guy Rouillier <guyr@burntmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

merge-one-file: fix broken merges with alternate work... Jeff King Fri, 29 Apr 2011 22:24:32 +0000 (18:24 -0400)

merge-one-file: fix broken merges with alternate work trees

The merge-one-file tool predates the invention of
GIT_WORK_TREE. By the time GIT_WORK_TREE was invented, most
people were using the merge-recursive strategy, which
handles resolving internally. Therefore these features have
had very little testing together.

For the most part, merge-one-file just works with
GIT_WORK_TREE; most of its heavy lifting is done by plumbing
commands which do respect GIT_WORK_TREE properly. The one
exception is a shell redirection which touches the worktree
directly, writing results to the wrong place in the presence
of a GIT_WORK_TREE variable.

This means that merges won't even fail; they will silently
produce incorrect results, throwing out the entire "theirs"
side of files which need content-level merging!

This patch makes merge-one-file chdir to the toplevel of the
working tree (and exit if we don't have one). This most
closely matches the assumption made by the original script
(before separate work trees were invented), and matches what
happens when the script is called as part of a merge
strategy.

While we're at it, we'll also error-check the call to cat.
Merging a file in a subdirectory could in fact fail, as the
redirection relies on the "checkout-index" call just prior
to create leading directories. But we never noticed, since
we ignored the error return from running cat.

Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

add tests for merge-index / merge-one-fileJeff King Fri, 29 Apr 2011 22:23:54 +0000 (18:23 -0400)

add tests for merge-index / merge-one-file

There were no tests for either, except a brief use in
t1200-tutorial.

These tools are not used much these days, as most people
use the merge-recursive strategy, which handles everything
internally. However, they are used by the "octopus" and
"resolve" strategies, as well as any custom strategies
or merge scripts people have built around them.

For example, together with read-tree, they are the simplest
way to do a basic content-level merge without checking out
the entire repository contents beforehand.

This script adds a basic test of the tools to perform one
content-level merge. It also shows a failure of the tools to
work properly in the face of GIT_WORK_TREE or core.worktree.

Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

"add -p": work-around an old laziness that does not... Junio C Hamano Wed, 6 Apr 2011 21:20:57 +0000 (14:20 -0700)

"add -p": work-around an old laziness that does not coalesce hunks

Since 0beee4c (git-add--interactive: remove hunk coalescing, 2008-07-02),
"git add--interactive" behaves lazily and passes overlapping hunks to the
underlying "git apply" without coalescing. This was partially corrected
by 7a26e65 (its partial revert, 2009-05-16), but overlapping hunks are
still passed when the patch is edited.

Teach "git apply" the --allow-overlap option that disables a safety
feature that avoids misapplication of patches by not applying patches
to overlapping hunks, and pass this option form "add -p" codepath.

Do not even advertise the option, as this is merely a workaround, and the
correct fix is to make "add -p" correctly coalesce adjacent patch hunks.

Signed-off-by: Junio C Hamano <gitster@pobox.com>

add--interactive.perl: factor out repeated --recount... Junio C Hamano Wed, 6 Apr 2011 21:12:34 +0000 (14:12 -0700)

add--interactive.perl: factor out repeated --recount option

Depending on the direction and the target of patch application, we would
need to pass --cached and --reverse to underlying "git apply". Also we
only pass --check when we are not applying but just checking.

But we always pass --recount since 8cbd431 (git-add--interactive: replace
hunk recounting with apply --recount, 2008-07-02). Instead of repeating
the same --recount over and over again, move it to a single place that
actually runs the command, namely, "run_git_apply" subroutine.

Signed-off-by: Junio C Hamano <gitster@pobox.com>

t3701: Editing a split hunk in an "add -p" sessionJunio C Hamano Fri, 29 Apr 2011 19:41:16 +0000 (12:41 -0700)

t3701: Editing a split hunk in an "add -p" session

Arnaud Lacombe reported that with the recent change to reject overlapping
hunks fed to "git apply", the edit mode of an "add -p" session that lazily
feeds overlapping hunks without coalescing adjacent ones claim that the
patch does not apply. Expose the problem to be fixed.

Cf. http://thread.gmane.org/gmane.comp.version-control.git/170685/focus=171000

Signed-off-by: Junio C Hamano <gitster@pobox.com>

add -p: 'q' should really quitJunio C Hamano Fri, 29 Apr 2011 22:12:32 +0000 (15:12 -0700)

add -p: 'q' should really quit

The "quit" command was added in 9a7a1e0 (git add -p: new "quit" command at
the prompt, 2009-04-10) to allow the user to say that hunks other than
what have already been chosen are undesirable, and exit the interactive
loop immediately. It forgot that there may be an undecided hunk before
the current one. In such a case, the interactive loop still goes back to
the beginning.

Clear all the USE bit for undecided hunks and exit the loop.

Signed-off-by: Junio C Hamano <gitster@pobox.com>