Sha256: 68acc76a2c8607e8377ad0ea62a17b0ad8aa2a442201dccea6ee1db59ea21b98
Contents?: true
Size: 754 Bytes
Versions: 1
Compression:
Stored size: 754 Bytes
Contents
require 'aptly_cli/version' require 'aptly_load' require 'httmultiparty' require 'json' module AptlyCli # Misc Aptly Class class AptlyMisc include HTTMultiParty # Load aptly-cli.conf and establish base_uri @config = AptlyCli::AptlyLoad.new.configure_with('/etc/aptly-cli.conf') base_uri "#{@config[:proto]}://#{@config[:server]}:#{@config[:port]}/api" if @config[:username] if @config[:password] basic_auth @config[:username].to_s, @config[:password].to_s end end debug_output $stdout if @config[:debug] == true def get_graph(extension) uri = "/graph.#{extension}" self.class.get(uri) end def get_version uri = '/version' self.class.get(uri) end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
aptly_cli-0.2.9 | lib/aptly_misc.rb |