Sha256: 46904ff7ffc6bd2ebab9e630725879fa9f4d38335f5454d9b64cce436d871227

Contents?: true

Size: 815 Bytes

Versions: 3

Compression:

Stored size: 815 Bytes

Contents

require 'sinatra/base'
require 'extlib'

module RatPack
  VERSION = '0.2.2'
  LIBPATH = ::File.expand_path(::File.dirname(__FILE__)) + ::File::SEPARATOR
  PATH = ::File.dirname(LIBPATH) + ::File::SEPARATOR

  def self.version
    VERSION
  end

  def self.libpath( *args )
    args.empty? ? LIBPATH : ::File.join(LIBPATH, args.flatten)
  end

  def self.path( *args )
    args.empty? ? PATH : ::File.join(PATH, args.flatten)
  end

  def self.require_all_libs_relative_to( fname, dir = nil )
    dir ||= ::File.basename(fname, '.*')
    search_me = ::File.expand_path(
        ::File.join(::File.dirname(fname), dir, '**', '*.rb'))
    Dir.glob(search_me).sort.each {|rb| require rb}
  end
end  # module RatPack

RatPack.require_all_libs_relative_to(__FILE__)
require File.join(RatPack::LIBPATH,'sinatra','ratpack')

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
BrianTheCoder-ratpack-0.2.2 lib/ratpack.rb
BrianTheCoder-ratpack-0.2.3 lib/ratpack.rb
BrianTheCoder-ratpack-0.2.4 lib/ratpack.rb