diff options
Diffstat (limited to 'lib/Youri/Package')
-rw-r--r-- | lib/Youri/Package/URPM.pm | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/lib/Youri/Package/URPM.pm b/lib/Youri/Package/URPM.pm index e26399e..2dcc317 100644 --- a/lib/Youri/Package/URPM.pm +++ b/lib/Youri/Package/URPM.pm @@ -375,13 +375,16 @@ sub sign { croak "Unsignable package, parent directory is read-only" unless -w $parent; + # FIXME Will have to change that + return !system("sudo -H /root/bin/resign_cooker $self->{_file}"); + my $command = 'LC_ALL=C rpm --resign ' . $self->{_file} . ' --define "_gpg_name ' . $name . '"' . ' --define "_gpg_path ' . $path . '"'; my $expect = Expect->spawn($command) or die "Couldn't spawn command $command: $!\n"; $expect->log_stdout(0); - $expect->expect(20, -re => 'Enter pass phrase:'); + $expect->expect(200, -re => 'Enter pass phrase:'); $expect->send("$passphrase\n"); $expect->soft_close(); @@ -394,6 +397,11 @@ sub extract { system("rpm2cpio $self->{_file} | cpio -id >/dev/null 2>&1"); } +sub is_debug { + my ($self) = @_; + return $self->{_header}->name() =~ /-debug$/; +} + =head1 COPYRIGHT AND LICENSE Copyright (C) 2002-2006, YOURI project |