Commit graph

32646 commits

Author SHA1 Message Date
Felipe Contreras 7655fa7fa9 completion: add more cherry-pick options
Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-04-12 10:43:20 -07:00
Junio C Hamano e2af9e361b Merge branch 'maint'
* maint:
  Typo fix: replacing it's -> its
  t: make PIPE a standard test prerequisite
  archive: clarify explanation of --worktree-attributes
  t/README: --immediate skips cleanup commands for failed tests
2013-04-11 17:41:48 -07:00
Junio C Hamano 7ece7ee607 Update dtaft release notes to 1.8.3
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-04-11 17:41:14 -07:00
Junio C Hamano a15696bb46 Merge branch 'ap/combine-diff-coalesce-lost'
Attempts to minimize "diff -c/--cc" output by coalescing the same
lines removed from the parents better, but with an O(n^2)
complexity.

* ap/combine-diff-coalesce-lost:
  combine-diff: coalesce lost lines optimally
2013-04-11 17:41:06 -07:00
Junio C Hamano 0d2f94ac95 Merge branch 'sr/log-SG-no-textconv'
"git log -S/-G" started paying attention to textconv filter, but
there was no way to disable this.  Make it honor --no-textconv
option.

* sr/log-SG-no-textconv:
  diffcore-pickaxe: unify code for log -S/-G
  diffcore-pickaxe: fix leaks in "log -S<block>" and "log -G<pattern>"
  diffcore-pickaxe: port optimization from has_changes() to diff_grep()
  diffcore-pickaxe: respect --no-textconv
  diffcore-pickaxe: remove fill_one()
  diffcore-pickaxe: remove unnecessary call to get_textconv()
2013-04-11 17:41:04 -07:00
Junio C Hamano 5beeefea31 Merge branch 'js/rerere-forget-protect-against-NUL'
A few bugfixes to "git rerere" working on corner case merge
conflicts.

* js/rerere-forget-protect-against-NUL:
  rerere forget: do not segfault if not all stages are present
  rerere forget: grok files containing NUL
2013-04-11 17:41:02 -07:00
Junio C Hamano b3569933dd Merge branch 'po/help-guides'
"git help" learned "-g" option to show the list of guides just like
list of commands are given with "-a".

* po/help-guides:
  doc: include --guide option description for "git help"
  help: mention -a and -g option, and 'git help <concept>' usage.
  builtin/help.c: add list_common_guides_help() function
  builtin/help.c: add --guide option
  builtin/help.c: split "-a" processing into two
2013-04-11 17:41:00 -07:00
Benoit Bourbie 3a51467b94 Typo fix: replacing it's -> its
Signed-off-by: Benoit Bourbie <benoit.bourbie@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-04-11 17:39:05 -07:00
Adam Spiers 200732744a t: make PIPE a standard test prerequisite
The 'PIPE' test prerequisite was already defined identically by t9010
and t9300, therefore it makes sense to make it a predefined
prerequisite.

Signed-off-by: Adam Spiers <git@adamspiers.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-04-11 17:39:05 -07:00
René Scharfe 59a7714c89 archive: clarify explanation of --worktree-attributes
Make it a bit clearer that --worktree-attributes is about files in the
working tree (checked out files, possibly changed) and not the current
working directory ($PWD).  Link to the ATTRIBUTES section, which has
more details.

Reported-by: Amit Bakshi <ambakshi@gmail.com>
Signed-off-by: Rene Scharfe <rene.scharfe@lsrfire.ath.cx>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-04-11 17:38:45 -07:00
Simon Ruderich 13cb3bb7e6 t/README: --immediate skips cleanup commands for failed tests
Signed-off-by: Simon Ruderich <simon@ruderich.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-04-09 15:12:28 -07:00
Felipe Contreras fa7285dc3d remote-bzr: improve tag handling
revision_history() is deprecated and doesn't do what we want (revno
instead of dotted_revno?).

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-04-08 14:17:07 -07:00
Christophe Simonis 5ff4fc649e remote-bzr: fix utf-8 support for fetching
The previous patches didn't deal with all the scenarios.

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-04-08 14:09:31 -07:00
Junio C Hamano 0290bf1250 Revert 4b7f53da76 (simplify-merges: drop merge from irrelevant side branch, 2013-01-17)
Kevin Bracey reports that the change regresses a case shown in the
user manual.

Trading one fix with another breakage is not worth it.  Just keep
the test to document the existing breakage, and revert the change
for now.

Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-04-08 13:10:27 -07:00
Junio C Hamano 52a3e011c7 Sync with 1.8.2.1
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-04-07 15:28:50 -07:00
Junio C Hamano 5bda18c186 Git 1.8.2.1
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-04-07 15:27:23 -07:00
Junio C Hamano c17b651f19 Update draft release notes to 1.8.3
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-04-07 14:40:26 -07:00
Junio C Hamano 0f3d66c6dc Merge branch 'jk/rm-removed-paths'
A handful of test cases and a corner case bugfix for "git rm".

* jk/rm-removed-paths:
  t3600: document failure of rm across symbolic links
  t3600: test behavior of reverse-d/f conflict
  rm: do not complain about d/f conflicts during deletion
2013-04-07 14:33:14 -07:00
Junio C Hamano e65cdde454 Merge branch 'tb/shared-perm'
Simplifies adjust_shared_perm() implementation.

* tb/shared-perm:
  path.c: optimize adjust_shared_perm()
  path.c: simplify adjust_shared_perm()
2013-04-07 14:33:11 -07:00
Junio C Hamano 60eea92b50 Merge branch 'cn/commit-amend-doc'
* cn/commit-amend-doc:
  Documentation/git-commit: reword the --amend explanation
2013-04-07 14:33:06 -07:00
Junio C Hamano 41e9da40a8 Merge branch 'fc/remote-helpers-test-updates'
* fc/remote-helpers-test-updates:
  remote-hg: fix hg-git test-case
  remote-bzr: remove stale check code for tests
  remote-helpers: fix the run of all tests
  remote-bzr: avoid echo -n
2013-04-07 14:33:02 -07:00
Junio C Hamano cd5123da9b Merge branch 'mg/texinfo-5'
Strip @anchor elements in the texinfo output of the documentation,
as a single document created by concatenating our entire manual set
will produce many duplicates that makes newer texinfo unhappy.

* mg/texinfo-5:
  Documentation: Strip texinfo anchors to avoid duplicates
2013-04-07 14:32:59 -07:00
Junio C Hamano 8a2decfec6 Merge branch 'jk/diffcore-break-divzero'
* jk/diffcore-break-divzero:
  diffcore-break: don't divide by zero
2013-04-07 14:32:57 -07:00
Junio C Hamano 252905dd4a Merge branch 'jk/bisect-prn-unsigned'
* jk/bisect-prn-unsigned:
  bisect: avoid signed integer overflow
2013-04-07 14:32:54 -07:00
Junio C Hamano 4d35924e3a Merge branch 'rr/triangle'
Support "pull from one place, push to another place" workflow
better by introducing remote.pushdefault (overrides the "origin"
thing) and branch.*.pushremote (overrides the branch.*.remote).

* rr/triangle:
  remote.c: introduce branch.<name>.pushremote
  remote.c: introduce remote.pushdefault
  remote.c: introduce a way to have different remotes for fetch/push
  t5516 (fetch-push): drop implicit arguments from helper functions
  t5516 (fetch-push): update test description
  remote.c: simplify a bit of code using git_config_string()
2013-04-07 14:32:50 -07:00
Junio C Hamano e64734b6a0 Merge branch 'mm/status-during-revert'
"git status" learned to report that you are in the middle of a
revert session, just like it does for a cherry-pick and a bisect
session.

* mm/status-during-revert:
  status: show commit sha1 in "You are currently reverting" message
  status: show 'revert' state and status hint
2013-04-07 14:32:03 -07:00
Junio C Hamano 88dccb6c98 Merge branch 'jk/set-upstream-error-cases'
The handing by "git branch --set-upstream-to" against various forms
of errorneous inputs were suboptimal.

* jk/set-upstream-error-cases:
  branch: give advice when tracking start-point is missing
  branch: mention start_name in set-upstream error messages
  branch: improve error message for missing --set-upstream-to ref
  branch: factor out "upstream is not a branch" error messages
  t3200: test --set-upstream-to with bogus refs
2013-04-07 14:31:08 -07:00
Junio C Hamano 9a11f13d9e Merge branch 'jk/filter-branch-come-back-to-original'
When used with "-d temporary-directory" option, "git filter-branch"
failed to come back to the original working tree to perform the
final clean-up procedure.

* jk/filter-branch-come-back-to-original:
  filter-branch: return to original dir after filtering
2013-04-07 14:29:34 -07:00
Junio C Hamano 6466fbbeef Sync with 1.8.1.6 2013-04-07 13:17:50 -07:00
Junio C Hamano 2137ce01f8 Git 1.8.1.6
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-04-07 08:58:30 -07:00
Junio C Hamano 4bbb830a35 Merge branch 'jc/directory-attrs-regression-fix' into maint-1.8.1
A pattern "dir" (without trailing slash) in the attributes file
stopped matching a directory "dir" by mistake with an earlier change
that wanted to allow pattern "dir/" to also match.

* jc/directory-attrs-regression-fix:
  t: check that a pattern without trailing slash matches a directory
  dir.c::match_pathname(): pay attention to the length of string parameters
  dir.c::match_pathname(): adjust patternlen when shifting pattern
  dir.c::match_basename(): pay attention to the length of string parameters
  attr.c::path_matches(): special case paths that end with a slash
  attr.c::path_matches(): the basename is part of the pathname
2013-04-07 08:45:03 -07:00
Torsten Bögershausen 0e9b327227 remote-helpers/test-bzr.sh: do not use "grep '\s'"
Using grep "devel\s\+3:" to find at least one whitspace is not
portable on all grep versions; not all grep versions understand "\s"
as a "whitespace".

Use a literal TAB followed by SPACE.

The + as a qualifier for "one or more" is not a basic regular
expression; use egrep instead of grep.

Signed-off-by: Torsten Bögershausen <tboegi@web.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-04-07 08:41:34 -07:00
John Keeping 9e7673ed7f gitremote-helpers(1): clarify refspec behaviour
The documentation says that "If no 'refspec' capability is advertised,
there is an implied `refspec *:*`" but this is only the case for the
"import" command.

Since there is a comment in transport-helper.c indicating that this
default is for historical reasons, change the documentation to clarify
that a refspec should always be specified.

Signed-off-by: John Keeping <john@keeping.me.uk>
Acked-by: Sverre Rabbelier <srabbelier@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-04-07 00:40:48 -07:00
Antoine Pelisse c4458ecdc5 fast-export: Allow pruned-references in mark file
fast-export can fail because of some pruned-reference when importing a
mark file.

The problem happens in the following scenario:

    $ git fast-export --export-marks=MARKS master
    (rewrite master)
    $ git prune
    $ git fast-export --import-marks=MARKS master

This might fail if some references have been removed by prune
because some marks will refer to no longer existing commits.
git-fast-export will not need these objects anyway as they were no
longer reachable.

We still need to update last_numid so we don't change the mapping
between marks and objects for remote-helpers.
Unfortunately, the mark file should not be rewritten without lost marks
if no new objects has been exported, as we could lose track of the last
last_numid.

Signed-off-by: Antoine Pelisse <apelisse@gmail.com>
Reviewed-by: Felipe Contreras <felipe.contreras@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-04-07 00:40:23 -07:00
Felipe Contreras 6ff8d4e748 remote-bzr: add utf-8 support for pushing
Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-04-07 00:39:28 -07:00
Timotheus Pokorra 5445b24e22 remote-bzr: add utf-8 support for fetching
[fc: added tests]

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-04-07 00:39:27 -07:00
Felipe Contreras 8954441ac7 remote-bzr: avoid unreferred tags
They have no content, there's nothing we can do with them.

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-04-07 00:39:27 -07:00
Felipe Contreras f00f2511d9 remote-bzr: only update workingtree on local repos
Apparently, that's the only way it's possible.

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-04-07 00:39:27 -07:00
David Engster 9d9d698c43 remote-bzr: set author if available
[fc: added tests]

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-04-07 00:39:27 -07:00
Christophe Simonis bc51f7c3e2 remote-bzr: remove files before modifications
Allow re-add of a deleted file in the same commit.

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-04-07 00:39:26 -07:00
Christophe Simonis 82447e3361 remote-bzr: fix directory renaming
Git does not handle directories, renaming a directory is renaming every
files in this directory.

[fc: added tests]

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-04-07 00:39:26 -07:00
Junio C Hamano 21ccebec0d Update draft release notes to 1.8.3
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-04-05 14:19:57 -07:00
Junio C Hamano 7cd895e59e Merge branch 'mh/rev-parse-verify-doc'
"rev-parse --verify" was documented in a misleading way.

* mh/rev-parse-verify-doc:
  rev-parse: clarify documentation for the --verify option
2013-04-05 14:15:20 -07:00
Junio C Hamano d5fec92a7a Merge branch 'sg/gpg-sig'
Teach "merge/pull" to optionally verify and reject commits that are
not signed properly.

* sg/gpg-sig:
  pretty printing: extend %G? to include 'N' and 'U'
  merge/pull Check for untrusted good GPG signatures
  merge/pull: verify GPG signatures of commits being merged
  commit.c/GPG signature verification: Also look at the first GPG status line
  Move commit GPG signature verification to commit.c
2013-04-05 14:15:16 -07:00
Junio C Hamano 7b72ec5e14 Merge branch 'jl/submodule-deinit'
A finishing touch to the new topic in 1.8.3.

* jl/submodule-deinit:
  submodule deinit: clarify work tree removal message
2013-04-05 14:15:13 -07:00
Junio C Hamano cb66027578 Merge branch 'rr/send-email-perl-critique'
Update "git send-email" for issues noticed by PerlCritic.

* rr/send-email-perl-critique:
  send-email: use the three-arg form of open in recipients_cmd
  send-email: drop misleading function prototype
  send-email: use "return;" not "return undef;" on error codepaths
2013-04-05 14:14:49 -07:00
Junio C Hamano e636241fdb Merge branch 'jc/merge-tag-object'
"git merge $(git rev-parse v1.8.2)" behaved quite differently from
"git merge v1.8.2" as if v1.8.2 were written as v1.8.2^0 and did
not pay much attention to the annotated tag payload.

This makes the code notice the type of the tag object, in addition
to the dwim_ref() based classification the current code uses
(i.e. the name appears in refs/tags/) to decide when to special
case merging of tags.

* jc/merge-tag-object:
  t6200: test message for merging of an annotated tag
  t6200: use test_config/test_unconfig
  merge: a random object may not necssarily be a commit
2013-04-05 14:14:41 -07:00
Torsten Bögershausen cbe43b8473 path.c: optimize adjust_shared_perm()
Sometimes the chown() function is called even when not needed (This
can be provoked by running t1301, and adding some debug code).

Save a chmod from 400 to 400, or from 600 to 600 on these files:

 .git/info/refs+
 .git/objects/info/packs+

Save chmod on directories from 2770 to 2770:

 .git/refs
 .git/refs/heads
 .git/refs/tags

Signed-off-by: Torsten Bögershausen <tboegi@web.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-04-05 12:39:38 -07:00
Torsten Bögershausen 3a429d3b8d path.c: simplify adjust_shared_perm()
All calls to set_shared_perm() use mode == 0, so simplify the
function.

Because all callers use the macro adjust_shared_perm(path) from
cache.h to call this function, convert it to a proper function,
losing set_shared_perm().

Since path.c has much more functions than just mkpath() these days,
drop the stale comment about it.

Signed-off-by: Torsten Bögershausen <tboegi@web.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-04-05 12:37:55 -07:00
Jeff King 61690bf4a1 diffcore-pickaxe: unify code for log -S/-G
The logic flow of has_changes() used for "log -S" and diff_grep()
used for "log -G" are essentially the same.  See if we have both
sides that could be different in any interesting way, slurp the
contents in core, possibly after applying textconv, inspect the
contents, clean-up and report the result.  The only difference
between the two is how "inspect" step works.

Unify this codeflow in a helper, pickaxe_match(), which takes a
callback function that implements the specific "inspect" step.

After removing the common scaffolding code from the existing
has_changes() and diff_grep(), they each becomes such a callback
function suitable for passing to pickaxe_match().

Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-04-05 10:31:09 -07:00