Top Level Namespace

Defined Under Namespace

Modules: AWS, Fog, Rackspace

Instance Method Summary collapse

Instance Method Details

#credentialsObject



6
7
8
9
10
11
12
13
14
# File 'bin/fog', line 6

def credentials
  @credentials ||= begin
    if ARGV[0] && File.exists?(File.expand_path(ARGV[0]))
      YAML.load(File.open(File.expand_path(ARGV[0])).read)
    elsif File.exists?(File.expand_path('~/.fog'))
      YAML.load(File.open(File.expand_path('~/.fog')).read)
    end
  end
end