lib/blazing/recipes/bundler_recipe.rb in blazing-0.0.7 vs lib/blazing/recipes/bundler_recipe.rb in blazing-0.0.8

- old
+ new

@@ -1,16 +1,20 @@ require 'blazing/recipe' module Blazing - class BundlerRecipe < Blazing::Recipe - def self.run - puts 'buhuuuuuu, running bundler!' - success + + def initialize(name, options = {}) + options[:flags] ||= '--deployment' + super(name, options) end - def self.success - puts 'yay, ran Bundler successfully!!!!!!' + def run + if File.exists?(File.join(Dir.pwd, 'Gemfile')) + @runner.run "bundle install #{@options[:flags]}" + else + false + end end - end + end end