Class: Codestrapfile

Inherits:
Object
  • Object
show all
Defined in:
lib/codestrap/config.rb

Class Method Summary collapse

Instance Method Summary collapse

Class Method Details

.config {|obj| ... } ⇒ Object

Yields:

  • (obj)


98
99
100
101
# File 'lib/codestrap/config.rb', line 98

def self.config
  obj = Codestrapfile.new()
  yield obj if block_given?
end

.localObject



74
75
76
# File 'lib/codestrap/config.rb', line 74

def self.local
  @@local ||= Codestrap::Local::Config.new
end

.serverObject



70
71
72
# File 'lib/codestrap/config.rb', line 70

def self.server
  @@server ||= Codestrap::Server::Config.new
end

Instance Method Details

#localObject



88
89
90
91
92
93
94
95
96
# File 'lib/codestrap/config.rb', line 88

def local
  @@local ||= Codestrap::Local::Config.new

  if block_given?
    yield @@local
  else
    @@local
  end
end

#serverObject



78
79
80
81
82
83
84
85
86
# File 'lib/codestrap/config.rb', line 78

def server
  @@server ||= Codestrap::Server::Config.new

  if block_given?
    yield @@server
  else
    @@server
  end
end