Class: Pbmenv::Helper

Inherits:
Object
  • Object
show all
Defined in:
lib/pbmenv/helper.rb

Class Method Summary collapse

Class Method Details

.normalize_version(version) ⇒ Object



12
13
14
# File 'lib/pbmenv/helper.rb', line 12

def self.normalize_version(version)
  /\Av?([\w.]*)\z/ =~ version && $1
end

.system_and_puts(shell) ⇒ Object



3
4
5
6
# File 'lib/pbmenv/helper.rb', line 3

def self.system_and_puts(shell)
  to_stdout "[SHELL] #{shell}"
  system(shell)
end

.to_stdout(text) ⇒ Object



8
9
10
# File 'lib/pbmenv/helper.rb', line 8

def self.to_stdout(text)
  Pbmenv.logger.info(text)
end