Sha256: c88623f6e454bf3927a4c06781a2cc1e26d0cadc5d0b34ac5979594445d86238
Contents?: true
Size: 839 Bytes
Versions: 1
Compression:
Stored size: 839 Bytes
Contents
Require ======= Manage your project's dependencies with a pretty DSL. * Gem activation * Require calls * Load paths * Gemspec configuration Install ------- <pre> sudo gem install require </pre> Example ------- Create <code>require.rb</code> in your project's root directory: <pre> require 'rubygems' require 'require' Require File.dirname(__FILE__) do gem(:sinatra, '=0.9.4') { require 'sinatra/base' } gem(:haml, '=2.2.16') { require %w(haml sass) } lib do gem :sinatra gem :haml load_path 'vendor/authlogic/lib' require 'authlogic' end end </pre> Then in your library file (<code>lib/whatever.rb</code>): <pre> require File.expand_path("#{File.dirname(__FILE_)}/../require") Require.lib! # Activates sinatra and haml gems # Adds vendor/authlogic/lib to the load paths # Requires authlogic </pre>
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
require-0.1.5 | README.markdown |