RubyGems Navigation menu

need 1.1.0

DESCRIPTION: Need makes ruby relative requires just work. Simply need a file with a relative path and the file will always be required correctly, regardless of what file your application is being launched through. Typically, ruby projects would unshift lib onto $PATH or use the File.dirname(__FILE__) trick. Using need means you don’t have to worry about either of these. Assume you have two files, one directly in lib and the other in lib/extensions. Let’s assume that file_a in lib requires file_b, in lib/extensions. Previously, you would doing some crazy load path unshifting or use the __FILE__ trick to make these requires flexible enough to work when your app is being accessed by rake, through a test suite, or required as a gem. Now, just use need. In file_a: need{"extensions/file_b"} need "extensions/file_b"

Gemfile:
= Copy to clipboard Copied!

instalar:
=

Versões:

  1. 1.1.0 - May 24, 2008* (5,5 KB)
  2. 1.0.3 - May 23, 2008* (5,5 KB)
  3. 1.0.2 - March 18, 2008* (5,5 KB)
  4. 1.0.1 - February 14, 2008* (5,5 KB)
  5. 1.0.0 - February 08, 2008* (5,5 KB)

Runtime Dependencies (1):

hoe >= 1.5.3

Donos:

Autores:

  • Drew Olson

SHA 256 checksum:

e34b17ffc6b64c406bfd9ab709d53eb5072763edc73ba5a63a6d5c2df645d20f

Total de downloads 19.711

Desta versão 5.614

Licenças:

N/A

Versão Requerida do Ruby: Nenhum

Links: