Class: Lhj::PgyerConfig

Inherits:
Object
  • Object
show all
Defined in:
lib/lhj/helper/pgyer_config.rb

Overview

pgyer config

Constant Summary collapse

CONFIG_NAME =
'pgyer_config.yml'

Class Method Summary collapse

Class Method Details

.api_keyObject



19
20
21
# File 'lib/lhj/helper/pgyer_config.rb', line 19

def self.api_key
  config['api_key']
end

.configObject



15
16
17
# File 'lib/lhj/helper/pgyer_config.rb', line 15

def self.config
  @yaml ||= YAML.load_file(config_file)
end

.config_fileObject



11
12
13
# File 'lib/lhj/helper/pgyer_config.rb', line 11

def self.config_file
  File.join(Lhj::Config.instance.home_dir, CONFIG_NAME)
end

.passwordObject



27
28
29
# File 'lib/lhj/helper/pgyer_config.rb', line 27

def self.password
  config['password']
end

.user_keyObject



23
24
25
# File 'lib/lhj/helper/pgyer_config.rb', line 23

def self.user_key
  config['user_key']
end