module PathLoader

Constants

VERSION

Public Class Methods

load(path) click to toggle source
# File lib/path_loader.rb, line 5
def load(path)
  $:.unshift(path)
end
load_relative(path) click to toggle source
# File lib/path_loader.rb, line 9
def load_relative(path)
  file = caller.first.split(/:\d/,2).first
  $:.unshift File.expand_path(path, File.dirname(file))
end