module PostyClient

Constants

VERSION

Public Class Methods

env() click to toggle source
# File lib/posty_client.rb, line 27
def self.env
  ENV['POSTY_ENV'] || 'development'
end
root() click to toggle source
# File lib/posty_client.rb, line 31
def self.root
  File.expand_path(File.dirname(__FILE__)+'/../')
end
settings_file() click to toggle source
# File lib/posty_client.rb, line 11
def self.settings_file
  default_file = File.expand_path('~/.posty_client.yml')

  @settings_file ||= if File.exists?(default_file)
    default_file
  else
    # this is set to make the cli not bark on missing settings
    PostyClient.root + '/config/posty_client.yml.dist'
  end
end
settings_file=(file_path) click to toggle source
# File lib/posty_client.rb, line 22
def self.settings_file=(file_path)
  @settings_file = file_path
  Settings.source(@settings_file)
end