Class: Bruw::Base

Inherits:
Object
  • Object
show all
Defined in:
lib/bruw/base.rb

Class Method Summary collapse

Class Method Details

.create_path(path) ⇒ Object



16
17
18
19
20
# File 'lib/bruw/base.rb', line 16

def self.create_path(path)
  return if Dir.exist?(path)

  FileUtils.mkpath(path)
end

.strip_path(path) ⇒ Object



9
10
11
12
13
14
# File 'lib/bruw/base.rb', line 9

def self.strip_path(path)
  return if path.nil? || path.empty?
  return path[0..-2] if path.end_with? "/"

  path
end

.versionObject



5
6
7
# File 'lib/bruw/base.rb', line 5

def self.version
  "0.0.1"
end