git-cherry-pick: Add keep-redundant-commits option

The git-cherry-pick --allow-empty command by default only preserves empty
commits that were originally empty, i.e only those commits for which
<commit>^{tree} and <commit>^^{tree} are equal.  By default commits which are
non-empty, but were made empty by the inclusion of a prior commit on the current
history are filtered out.  This option allows us to override that behavior and
include redundant commits as empty commits in the change history.

Note that this patch changes the default behavior of git cherry-pick slightly.
Prior to this patch all commits in a cherry-pick sequence were applied and git
commit was run.  The implication here was that, if a commit was redundant, and
the commit did not trigger the fast forward logic, the git commit operation, and
therefore the git cherry-pick operation would fail, displaying the cherry pick
advice (i.e. run git commit --allow-empty).  With this patch however, such
redundant commits are automatically skipped without stopping, unless
--keep-redundant-commits is specified, in which case, they are automatically
applied as empty commits.

Signed-off-by: Neil Horman <nhorman@tuxdriver.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
fixup! git-cherry-pick: Add keep-redundant-commits option

s/Add keep/add keep/
git-cherry-pick: Add test to validate new options

Since we've added the --allow-empty and --keep-redundant-commits
options to git cherry-pick we should also add a test to ensure that its working
properly.

Signed-off-by: Neil Horman <nhorman@tuxdriver.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
fixup! git-cherry-pick: Add test to validate new options

s/Add test/add test/ as well.
git-rebase: add keep_empty flag

Add a command line switch to git-rebase to allow a user the ability to specify
that they want to keep any commits in a series that are empty.

When git-rebase's type is am, then this option will automatically keep any
commit that has a tree object identical to its parent.

This patch changes the default behavior of interactive rebases as well.  With
this patch, git-rebase -i will produce a revision set passed to
git-revision-editor, in which empty commits are commented out.  Empty commits
may be kept manually by uncommenting them.  If the new --keep-empty option is
used in an interactive rebase the empty commits will automatically all be
uncommented in the editor.

Signed-off-by: Neil Horman <nhorman@tuxdriver.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
fixup! git-rebase: add keep_empty flag
Merge branch 'jk/repack-no-explode-objects-from-old-pack' into pu

By Jeff King
* jk/repack-no-explode-objects-from-old-pack:
  gc: use argv-array for sub-commands
  argv-array: add a new "pushl" method
  argv-array: refactor empty_argv initialization
Merge branch 'fc/completion-tests' into pu

Will merge to 'next'.

By SZEDER Gábor
* fc/completion-tests:
  tests: add tests for the __gitcomp() completion helper function
Merge branch 'tr/xdiff-fast-hash' into pu

Will merge to 'next'.

By Thomas Rast
* tr/xdiff-fast-hash:
  xdiff: load full words in the inner loop of xdl_hash_record
Merge branch 'cb/http-multi-curl-auth' into pu

Fixes http authentication breakage when we keep multiple HTTP requests in
flight using curl-multi.

Will merge to 'next'.

By Jeff King (3) and Clemens Buchacher (1)
* cb/http-multi-curl-auth:
  http: use newer curl options for setting credentials
  http: clean up leak in init_curl_http_auth
  fix http auth with multiple curl handles
  http auth fails with multiple curl handles
Merge branch 'zj/upstream-error-message' into pu

Will merge to 'next'.

By Zbigniew Jędrzejewski-Szmek
* zj/upstream-error-message:
  i18n: mark @{upstream} error messages for translation
  Be more specific if upstream branch is not tracked
  Provide better message for barnhc_wiht_tpyo@{u}
  Provide branch name in error message when using @{u}
  t1507: add tests to document @{upstream} behaviour
Merge branch 'nl/http-proxy-more' into pu

<<
>>

The code to talk to http proxies learn to use the same credential
API used to talk to the final http destinations.  This still needs
to peek into $ENV{HTTPS_PROXY}.

By Nelson Benitez Leon (5) and others
* nl/http-proxy-more:
  http: fix proxy password passing
  http: fix proxy authentication
  http: rename HTTP_REAUTH to HTTP_AUTH_RETRY
  http: Avoid limit of retrying request only twice
  http: handle proxy authentication failure (error 407)
  http: handle proxy proactive authentication
  http: try http_proxy env var when http.proxy config option is not set
Merge branch 'mm/push-default-switch-warning' into pu

This resurrects an ancient patch I wrote during a discussion we had in the
1.6.3-1.6.4 era.  This should probably come after ct/advise-push-default
topic and at that point the advise messages need to be rephrased, taking
the future default change into account.

By Clemens Buchacher (1) and Matthieu Moy (1)
* mm/push-default-switch-warning:
  t5570: use explicit push refspec
  push: start warning upcoming default change for push.default

Conflicts:
	builtin/push.c
Merge branch 'jc/split-blob' into pu

<<
>>

Not ready.

I finished the streaming checkout codepath, but as explained in
127b177 (bulk-checkin: support chunked-object encoding, 2011-11-30),
these are still early steps of a long and painful journey. At least
pack-objects and fsck need to learn the new encoding for the series
to be usable locally, and then index-pack/unpack-objects needs to
learn it to be used remotely.

Given that I heard a lot of noise that people want large files, and
that I was asked by somebody at GitTogether'11 privately for an
advice on how to pay developers (not me) to help adding necessary
support, I am somewhat dissapointed that the original patch series
that was sent almost two months ago still remains here without much
comments and updates from the developer community. I even made the
interface to the logic that decides where to split chunks easily
replaceable, and I deliberately made the logic in the original patch
extremely stupid to entice others, especially the "bup" fanboys, to
come up with a better logic, thinking that giving people an easy
target to shoot for, they may be encouraged to help out. The plan is
not working :-(.

* jc/split-blob:
  chunked-object: streaming checkout
  chunked-object: fallback checkout codepaths
  bulk-checkin: support chunked-object encoding
  bulk-checkin: allow the same data to be multiply hashed
  new representation types in the packstream
  packfile: use varint functions

Conflicts:
	t/t1050-large.sh
Merge branch 'jc/run-hook-env-1' into pu

Not urgent.

Updates run_hook() API to be much less specific to "commit".  It would
only be useful if people start doing more interesting things with hooks.

* jc/run-hook-env-1:
  run_hook(): enhance the interface to pass arbitrary environment
Merge branch 'th/difftool-diffall' into pu

Rolls the two-directory-diff logic from diffall script (in contrib/) into
"git difftool" framework.

Still being reworked.

By Tim Henigan
* th/difftool-diffall:
  difftool: print list of valid tools with '--tool-help'
  difftool: teach difftool to handle directory diffs
  difftool: eliminate setup_environment function
  difftool: stop appending '.exe' to git
  difftool: remove explicit change of PATH
  difftool: exit(0) when usage is printed
  difftool: add '--no-gui' option
  difftool: parse options using Getopt::Long
Merge branch 'nd/threaded-index-pack' into pu

<<
>>

J6t reports breakage on msysgit.

By Nguyễn Thái Ngọc Duy (3) and Ramsay Jones (1)
* nd/threaded-index-pack:
  index-pack: disable threading if NO_PREAD is defined
  index-pack: support multithreaded delta resolving
  index-pack: split second pass obj handling into own function
  compat/win32/pthread.h: Add an pthread_key_delete() implementation
Merge branch 'nd/columns' into pu

Will merge to 'next'.

By Nguyễn Thái Ngọc Duy
* nd/columns:
  tag: add --column
  column: support piping stdout to external git-column process
  status: add --column
  branch: add --column
  help: reuse print_columns() for help -a
  column: add dense layout support
  column: add columnar layout
  Stop starting pager recursively
  Add column layout skeleton and git-column

Conflicts:
	builtin/branch.c
Merge branch 'cb/daemon-test-race-fix' into pu

<<
>>

Fix race condition between starting and waiting for git-daemon in the
test.

By Clemens Buchacher
* cb/daemon-test-race-fix:
  git-daemon wrapper to wait until daemon is ready
Merge branch 'lp/diffstat-with-graph' into pu

Looked reasonable.
Will merge to 'next'.

By Lucian Poston (5) and Zbigniew Jędrzejewski-Szmek (1)
* lp/diffstat-with-graph:
  Prevent graph_width of stat width from falling below min
  t4052: Test diff-stat output with minimum columns
  t4052: Adjust --graph --stat output for prefixes
  Adjust stat width calculations to take --graph output into account
  Add output_prefix_length to diff_options
  t4052: test --stat output with --graph