Module: FunWith::Files::RootPathExtensions

Defined in:
lib/fun_with/files/root_path.rb

Instance Method Summary collapse

Instance Method Details

#root(*args, &block) ⇒ Object



4
5
6
7
8
9
10
11
# File 'lib/fun_with/files/root_path.rb', line 4

def root( *args, &block )
  if args.length > 0
    args.unshift( @root_path )
    FilePath.new( *args, &block )
  else
    FilePath.new( @root_path, &block )
  end
end

#set_root_path(path) ⇒ Object



13
14
15
# File 'lib/fun_with/files/root_path.rb', line 13

def set_root_path( path )
  @root_path = FunWith::Files::FilePath.new( path )
end