Sha256: 9fe05928a8b7a26bbf1631aa37c298af8c5122dcec79aa0b3d83f864c8af00c5
Contents?: true
Size: 815 Bytes
Versions: 1
Compression:
Stored size: 815 Bytes
Contents
require "bundler/gem_tasks" require "net/http" require "ssl_scan/util" namespace :gettext do desc 'generate mo files' task :mo do src = 'ssl_scan.po' target = 'ssl_scan.mo' Dir["locale/**"].each do |dir| cmd = "msgfmt #{File.join(dir, src)} -o #{File.join(dir, 'LC_MESSAGES', target)}" puts "Running command: #{cmd}" system(cmd) end end end namespace :ssl do desc 'fetch cacert from curl site' task :get_cert do uri = URI("http://curl.haxx.se") http = Net::HTTP.new(uri.host, uri.port) req = Net::HTTP::Get.new('/ca/cacert.pem') res = http.request(req) target_file = File.join(SSLScan::Util::ROOT, "data/cacert.pem") File.open(target_file, "w+") do |f| puts "writing to file: #{target_file}" f.write(res.body) end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
ssl_scan-0.0.6 | Rakefile |