Class: BundlerExt::Output

Inherits:
Object
  • Object
show all
Defined in:
lib/bundler_ext/output.rb

Class Method Summary collapse

Class Method Details

.parse_envObject



3
4
5
6
# File 'lib/bundler_ext/output.rb', line 3

def self.parse_env
  @nostrict = ENV['BEXT_NOSTRICT'] || ENV['BUNDLER_EXT_NOSTRICT']
  @verbose = ENV['BEXT_VERBOSE'] || ENV['BUNDLER_EXT_VERBOSE']
end

.strict_err(msg) ⇒ Object



8
9
10
11
12
13
14
15
# File 'lib/bundler_ext/output.rb', line 8

def self.strict_err(msg)
  parse_env
  if @nostrict
    puts msg
  else
    raise msg
  end
end

.verbose_msg(msg) ⇒ Object



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

def self.verbose_msg(msg)
  puts msg if @verbose
end