]> git.ipfire.org Git - thirdparty/git.git/commitdiff
Merge branch 'pb/log-first-parent-p-m'
authorJunio C Hamano <gitster@pobox.com>
Wed, 24 Mar 2010 23:25:39 +0000 (16:25 -0700)
committerJunio C Hamano <gitster@pobox.com>
Wed, 24 Mar 2010 23:25:39 +0000 (16:25 -0700)
* pb/log-first-parent-p-m:
  show --first-parent/-m: do not default to --cc
  show -c: show patch text
  revision: introduce setup_revision_opt
  t4013: add tests for log -p -m --first-parent
  git log -p -m: document -m and honor --first-parent

1  2 
Documentation/rev-list-options.txt
builtin/diff-tree.c
builtin/log.c
revision.c

Simple merge
Simple merge
diff --cc builtin/log.c
Simple merge
diff --cc revision.c
index 490b484084e875e9b6c5aea1168437bba4bb500a,2ddbb5086806a5b832caa9e14ffb1f326cd77c38..0471cd3f7ead19f1dbde87e610408d91e73e3949
@@@ -1332,9 -1328,9 +1332,9 @@@ static void append_prune_data(const cha
   * Returns the number of arguments left that weren't recognized
   * (which are also moved to the head of the argument list)
   */
- int setup_revisions(int argc, const char **argv, struct rev_info *revs, const char *def)
+ int setup_revisions(int argc, const char **argv, struct rev_info *revs, struct setup_revision_opt *opt)
  {
 -      int i, flags, left, seen_dashdash, read_from_stdin;
 +      int i, flags, left, seen_dashdash, read_from_stdin, got_rev_arg = 0;
        const char **prune_data = NULL;
  
        /* First, search for "--" */
                revs->prune_data = get_pathspec(revs->prefix, prune_data);
  
        if (revs->def == NULL)
-               revs->def = def;
+               revs->def = opt ? opt->def : NULL;
+       if (opt && opt->tweak)
+               opt->tweak(revs, opt);
        if (revs->show_merge)
                prepare_show_merge(revs);
 -      if (revs->def && !revs->pending.nr) {
 +      if (revs->def && !revs->pending.nr && !got_rev_arg) {
                unsigned char sha1[20];
                struct object *object;
                unsigned mode;