lib/aptly_load.rb in aptly_cli-0.2.5 vs lib/aptly_load.rb in aptly_cli-0.2.6

- old
+ new

@@ -3,10 +3,14 @@ require 'logger' module AptlyCli # Load aptly-cli configuration class AptlyLoad + def config + @config + end + def initialize @log = Logger.new(STDOUT) @log.level = Logger::WARN # Configuration defaults @@ -28,21 +32,17 @@ # Configure through yaml file def configure_with(path_to_yaml_file) begin config = YAML.load(IO.read(path_to_yaml_file)) rescue Errno::ENOENT - @log.warn('YAML configuration file couldn\'t be found at - /etc/aptly-cli.conf. Using defaults.') + @log.warn( + 'YAML configuration file couldn\'t be found at /etc/aptly-cli.conf. Using defaults.') return @config rescue Psych::SyntaxError @log.warn( 'YAML configuration file contains invalid syntax. Using defaults.') return @config end configure(config) - end - - def config - @config end end end