Kibou 希望 (Hope)
=============
Homebrew and Rake are OSX's best friends.
Features
Kibou is using Homebrew and Rake to manage your OSX configuration with only single rake
command.
Dependencies
OSX
Installation
gem install kibou
Example / Usage
Recipe
# recipes/tools.rb
class Tools < Kibou::Recipe
package :tmux, :ensure => :latest
package :wemux, :via => "https://github.com/downloads/zolrath/wemux/wemux.rb"
package :vim do
run 'brew install vim'
end
before :greeting
after :test_tmux
def greeting
run 'echo hello world'
end
def test_tmux
status = system("which tmux")
puts status ? "tmux is installed" : "tmux is not installed"
end
end
Rakefile
require 'kibou'
Kibou::RakeTask.new do |c|
c.recipes_directory = "recipes/*.rb"
c.recipes = ["tools"]
end
Run rake kibou
to perform package installations via Homebrew.
Documentation
Kibou::RakeTask
configuration
recipes_directory
- specify the directory name of recipe files in a regex pattern (default:recipes/*.rb
)recipes
- a list of recipe names (Array is preferred)
Kibou::Recipe
Ensure that recipe file name is match to the class name or Kibou will fail to start.
Example:
tools.rb
isTools
,blah.rb
isBlah
Notes: file names with underscore is not currently supported.
** package's options (Hash) **
:ensure
- ensures that package is:installed
or:latest
(default::installed
):via
- downloads a file from url or install from local file.
Thanks
Inspired by two popular tools: Puppet and Chef. They are amazing automated server framework tools.
License
Kibou is licensed under the MIT license.