Module: CookbookBumper

Defined in:
lib/cookbook_bumper.rb,
lib/cookbook_bumper/git.rb,
lib/cookbook_bumper/envs.rb,
lib/cookbook_bumper/config.rb,
lib/cookbook_bumper/envfile.rb,
lib/cookbook_bumper/version.rb,
lib/cookbook_bumper/metadata.rb,
lib/cookbook_bumper/cookbooks.rb,
lib/cookbook_bumper/rake_task.rb

Defined Under Namespace

Classes: Config, Cookbooks, EnvFile, Envs, Git, Metadata, RakeTask, Version

Constant Summary collapse

VERSION =
'0.1.0'

Class Method Summary collapse

Class Method Details

.configObject



17
18
19
# File 'lib/cookbook_bumper.rb', line 17

def self.config
  @config ||= Config.new
end

.configure {|config| ... } ⇒ Object

Yields:



13
14
15
# File 'lib/cookbook_bumper.rb', line 13

def self.configure
  yield config
end

.cookbooksObject



21
22
23
# File 'lib/cookbook_bumper.rb', line 21

def self.cookbooks
  @cookbooks ||= Cookbooks.new(config.cookbook_path)
end

.run(override_config = nil) ⇒ Object



25
26
27
28
29
30
31
32
33
# File 'lib/cookbook_bumper.rb', line 25

def self.run(override_config = nil)
  @config = override_config if override_config
  envs = Envs.new(config.environment_path)
  git = Git.new

  git.bump_changed
  envs.update
  puts envs.change_log
end