Sha256: 5237cd336d6478fd0e41866895da42dc9f5829ba9aa3f60e86cae1a3896d7998

Contents?: true

Size: 545 Bytes

Versions: 47

Compression:

Stored size: 545 Bytes

Contents

module BootstrapLeather
  module Generators
    module Utils
      def output(output, color = :green)
        say("           -  #{output}", color)
      end

      def ask_for(wording, default_value = nil, override_if_present_value = nil)
        override_if_present_value.present? ?
          display("Using [#{override_if_present_value}] for question '#{wording}'") && override_if_present_value :
          ask("           ?  #{wording} Press <enter> for [#{default_value}] >", :yellow).presence || default_value
      end
    end
  end
end

Version data entries

47 entries across 47 versions & 1 rubygems

Version Path
bootstrap_leather-0.9.4 lib/generators/bootstrap_leather/utils.rb
bootstrap_leather-0.9.3 lib/generators/bootstrap_leather/utils.rb
bootstrap_leather-0.9.2 lib/generators/bootstrap_leather/utils.rb
bootstrap_leather-0.9.1 lib/generators/bootstrap_leather/utils.rb
bootstrap_leather-0.9.0 lib/generators/bootstrap_leather/utils.rb
bootstrap_leather-0.8.8 lib/generators/bootstrap_leather/utils.rb
bootstrap_leather-0.8.7 lib/generators/bootstrap_leather/utils.rb
bootstrap_leather-0.8.6 lib/generators/bootstrap_leather/utils.rb
bootstrap_leather-0.8.5 lib/generators/bootstrap_leather/utils.rb
bootstrap_leather-0.8.4 lib/generators/bootstrap_leather/utils.rb
bootstrap_leather-0.8.3 lib/generators/bootstrap_leather/utils.rb
bootstrap_leather-0.8.2 lib/generators/bootstrap_leather/utils.rb
bootstrap_leather-0.8.1 lib/generators/bootstrap_leather/utils.rb
bootstrap_leather-0.8.0 lib/generators/bootstrap_leather/utils.rb
bootstrap_leather-0.7.4 lib/generators/bootstrap_leather/utils.rb
bootstrap_leather-0.7.3 lib/generators/bootstrap_leather/utils.rb
bootstrap_leather-0.7.1 lib/generators/bootstrap_leather/utils.rb
bootstrap_leather-0.7.0 lib/generators/bootstrap_leather/utils.rb
bootstrap_leather-0.6.3 lib/generators/bootstrap_leather/utils.rb
bootstrap_leather-0.6.2 lib/generators/bootstrap_leather/utils.rb