our $action = shift @ARGV // die "need ACTION";
our $publicmode = 02775;
-our $new_upload_propagation_slop = 3600*4 + 100;
+our $new_upload_propagation_slop = 3600*4 + 100;# fixme config;
our $poldbh;
our $pkg;
sub action_push_confirm () {
getpackage();
- die unless @ARGV;
- my $freshrepo = shift @ARGV;
+ die unless @ARGV >= 5;
+ my $freshrepo = $ARGV[4];
my $initq = $poldbh->prepare(<<END);
SELECT taint_id, gitobjid FROM taints t
my $oldmode = ((stat _)[2]);
my $oldwrites = $oldmode & 0222;
# remove r and x bits which have corresponding w bits clear
- my $newmode = $oldmode & ($oldwrites << 1) & ($oldwrites > 1);
+ my $newmode = $oldmode &
+ (~0555 | ($oldwrites << 1) | ($oldwrites >> 1));
+ printdebug sprintf "chmod %#o (was %#o) %s\n",
+ $newmode, $oldmode, $freshrepo;
chmod $newmode, $freshrepo or die $!;
}
}