sub rm (@) {
foreach my $file (@_) {
debug(sub{"file=$file\n"});
- if (not -e $file) {
+ if (-e $file) {
unlink($file)
or error("rm $file");
}
}
sub grg_decrypt_symmetric ($$$;$) {
my ($ctx, $key, $run) = @_;
- debug(sub{'ctx='}, $ctx);
- debug(sub{'key='}, $key);
$run = sub {return @_} unless defined $run;
IPC::Run::run($run->([@{$ctx->{config}->{gpg}}
, '--batch', '--no-default-keyring', '--keyring', '/dev/null', '--secret-keyring', '/dev/null'
}
$manifest_refs->{HEAD}
= $push_refs->[-1]->{src_obj}
- unless exists $manifest_refs->{HEAD}
- or @$push_refs == 0;
+ unless @$push_refs == 0;
grg_manifest_push($ctx);
grg_disconnect($ctx);
}