|
|
|
@ -45,6 +45,10 @@ OptionParser.new do |opts|
|
|
|
|
|
opts.on("-d DEST", "--destination DEST", "directory to place signature in") do |v|
|
|
|
|
|
@options[:destination] = v
|
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
opts.on("-p PROG", "--signing_program PROG", "specify signing program to use") do |v|
|
|
|
|
|
@options[:program] = v
|
|
|
|
|
end
|
|
|
|
|
end.parse!
|
|
|
|
|
|
|
|
|
|
base_dir = Pathname.new(__FILE__).expand_path.dirname.parent
|
|
|
|
@ -76,6 +80,7 @@ result['type'] = 'build'
|
|
|
|
|
result['optionals'] = optionals
|
|
|
|
|
|
|
|
|
|
signer = @options[:signer] or raise "must supply signer with --signer"
|
|
|
|
|
program = @options[:program] || "gpg --detach-sign"
|
|
|
|
|
|
|
|
|
|
FileUtils.mkdir_p(destination)
|
|
|
|
|
|
|
|
|
@ -85,4 +90,4 @@ assert_path = File.join(release_path, "#{package_name}-build.assert")
|
|
|
|
|
File.open(assert_path, "w") do |io|
|
|
|
|
|
io.write result.to_yaml
|
|
|
|
|
end
|
|
|
|
|
system!("gpg --detach-sign -u \"#{signer}\" \"#{assert_path}\"")
|
|
|
|
|
system!("#{program} -u \"#{signer}\" \"#{assert_path}\"")
|
|
|
|
|