Sha256: 7487e6679d9a5ac81e2993a92432a1ce248b59924b974c1cf0e18dbd3ce0ee99
Contents?: true
Size: 580 Bytes
Versions: 10
Compression:
Stored size: 580 Bytes
Contents
module SecretsCli class Configuration attr_reader :environment, :verbose def initialize(options) @environment = options.environment || ENV['RAILS_ENV'] || ENV['NODE_ENV'] || 'development' @verbose = options.verbose end def config @config ||= YAML.load_file(SECRETS_CONFIG_FILE) end def secrets_file config[:secrets_file] end def secrets_storage_key config[:secrets_storage_key] end def self.write(config) File.open(SECRETS_CONFIG_FILE, 'w') { |file| file.write(config.to_yaml) } end end end
Version data entries
10 entries across 10 versions & 1 rubygems