diff -r 000000000000 -r 98411ab74262 bin/sign-unsigned-changes --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/bin/sign-unsigned-changes Fri Jul 03 15:23:10 2009 +0200 @@ -0,0 +1,30 @@ +#!/usr/bin/perl + +use strict; +use File::Find; + +my $incoming = "/home/apt/incoming"; + +my @unsigned = qw( + + freeradius_1.0.0+cvs20040609-0.hs.5_i386.changes + +); + +my $vc = "gpg --verify"; +my $cc = "gpg --clearsign"; + +for (@unsigned) { + + my $f = "$incoming/$_"; + + # since we use a fixed list of unsigned files we shouldnt sign them twice + my $r = qx/$vc $f 2>&1/; + next unless $?; + + print "Attempting to sign [$f] .. "; + system("$cc $f") == 0 or warn "system([$cc] [$f]) failed: [$?] [$!]\n"; + rename("$f.asc", $f) or warn "rename([$f.asc], [$f]) failed: [$!]\n"; + print "finished\n"; + +}