Module: FeCoreExt::CoreExt::PathnameClassMethods

Included in:
Pathname
Defined in:
lib/fe_core_ext/core_ext/pathname.rb

Instance Method Summary collapse

Instance Method Details

#join(*args) ⇒ Object



50
51
52
# File 'lib/fe_core_ext/core_ext/pathname.rb', line 50

def join(*args)
  new(File.join(*args))
end

#mktmpdir(prefix_suffix = nil, tmpdir = nil) ⇒ Object



54
55
56
57
58
59
60
61
62
# File 'lib/fe_core_ext/core_ext/pathname.rb', line 54

def mktmpdir(prefix_suffix = nil, tmpdir = nil)
  if block_given?
    Dir.mktmpdir prefix_suffix, tmpdir do |dir|
      yield new(dir)
    end
  else
    new(Dir.mktmpdir(prefix_suffix, tmpdir))
  end
end