~ubuntu-branches/ubuntu/intrepid/git-core/intrepid-updates

« back to all changes in this revision

Viewing changes to git-cvsexportcommit.perl

  • Committer: Package Import Robot
  • Author(s): Gerrit Pape
  • Date: 2007-11-19 12:32:11 UTC
  • mfrom: (1.1.25)
  • Revision ID: package-import@ubuntu.com-20071119123211-h8x0kryv8anhjoot
Tags: 1:1.5.3.6-1
* debian/implicit: add proper dependencies to support 'parallel build'
  through make -j (thx Daniel Schepler for the patch).
* debian/rules: support 'nocheck' in DEB_BUILD_OPTIONS to skip running
  the selftests.
* debian/diff/0003-bug-448655-check-etc-mailname-if-author-email-is-un.diff:
  new; check /etc/mailname if author email is unknown (closes: #448655).
* debian/gitweb.docs: new; install gitweb/README.
* new upstream point release.
  * git-cvsimport: really convert underscores in branch names to dots with
    -u (closes: #446495).
  * git-mailsplit: with maildirs not only process cur/, but also new/
    (closes: #447396).
* debian/diff/0004-contrib-hooks-post-receive-email-make-subject-prefix.diff:
  new; cherry-pick'ed from master: contrib/hooks/post-receive-email: make
  subject prefix configurable (closes: #428418).

Show diffs side-by-side

added added

removed removed

Lines of Context:
87
87
    }
88
88
}
89
89
 
 
90
my $noparent = "0000000000000000000000000000000000000000";
90
91
if ($parent) {
91
92
    my $found;
92
93
    # double check that it's a valid parent
100
101
} else { # we don't have a parent from the cmdline...
101
102
    if (@parents == 1) { # it's safe to get it from the commit
102
103
        $parent = $parents[0];
103
 
    } else { # or perhaps not!
104
 
        die "This commit has more than one parent -- please name the parent you want to use explicitly";
 
104
    } elsif (@parents == 0) { # there is no parent
 
105
        $parent = $noparent;
 
106
    } else { # cannot choose automatically from multiple parents
 
107
        die "This commit has more than one parent -- please name the parent you want to use explicitly";
105
108
    }
106
109
}
107
110
 
121
124
}
122
125
close MSG;
123
126
 
124
 
`git-diff-tree --binary -p $parent $commit >.cvsexportcommit.diff`;# || die "Cannot diff";
 
127
if ($parent eq $noparent) {
 
128
    `git-diff-tree --binary -p --root $commit >.cvsexportcommit.diff`;# || die "Cannot diff";
 
129
} else {
 
130
    `git-diff-tree --binary -p $parent $commit >.cvsexportcommit.diff`;# || die "Cannot diff";
 
131
}
125
132
 
126
133
## apply non-binary changes
127
134