summary |
shortlog |
log |
commit | commitdiff |
tree
raw |
patch |
inline | side by side (from parent 1:
91c2126)
We can't easily do this to read_tree_upstream because that needs to
put debian/ back which is awkward.
Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
runcmd @git, qw(read-tree), "--prefix=$subdir/", $new_tree_object;
}
runcmd @git, qw(read-tree), "--prefix=$subdir/", $new_tree_object;
}
+sub read_tree_debian ($) {
+ my ($treeish) = @_;
+ read_tree_subdir 'debian', "$treeish:debian";
+ rm_subdir_cached 'debian/patches';
+}
+
sub make_commit ($$) {
my ($parents, $message_paras) = @_;
my $tree = cmdoutput @git, qw(write-tree);
sub make_commit ($$) {
my ($parents, $message_paras) = @_;
my $tree = cmdoutput @git, qw(write-tree);
- my $read_tree_debian = sub {
- my ($treeish) = @_;
- read_tree_subdir 'debian', "$treeish:debian";
- rm_subdir_cached 'debian/patches';
- };
my $read_tree_upstream = sub {
my ($treeish) = @_;
runcmd @git, qw(read-tree), $treeish;
my $read_tree_upstream = sub {
my ($treeish) = @_;
runcmd @git, qw(read-tree), $treeish;
- $read_tree_debian->($build);
+ read_tree_debian($build);
};
$#upp_cl = $upp_limit if defined $upp_limit;
};
$#upp_cl = $upp_limit if defined $upp_limit;
printdebug "WALK BUILD ".($cltree//'undef').
" $method (rewriting=$rewriting)\n";
if ($method eq 'Debian') {
printdebug "WALK BUILD ".($cltree//'undef').
" $method (rewriting=$rewriting)\n";
if ($method eq 'Debian') {
- $read_tree_debian->($cltree);
+ read_tree_debian($cltree);
} elsif ($method eq 'Upstream') {
$read_tree_upstream->($cltree);
} elsif ($method eq 'StartRewrite') {
} elsif ($method eq 'Upstream') {
$read_tree_upstream->($cltree);
} elsif ($method eq 'StartRewrite') {
$breakwater = $build;
next;
} elsif ($method eq 'DgitImportDebianUpdate') {
$breakwater = $build;
next;
} elsif ($method eq 'DgitImportDebianUpdate') {
- $read_tree_debian->($cltree);
+ read_tree_debian($cltree);
} elsif ($method eq 'DgitImportUpstreamUpdate') {
confess unless $rewriting;
my $differs = (get_differs $build, $cltree);
} elsif ($method eq 'DgitImportUpstreamUpdate') {
confess unless $rewriting;
my $differs = (get_differs $build, $cltree);