Method: Logging.path
- Defined in:
- lib/logging.rb
.path(*args, &block) ⇒ Object
Returns the lpath for the module. If any arguments are given, they will be joined to the end of the path using File.join.
408 409 410 411 412 413 414 415 416 417 418 419 |
# File 'lib/logging.rb', line 408 def path( *args, &block ) rv = args.empty? ? PATH : ::File.join(PATH, args.flatten) if block begin $LOAD_PATH.unshift PATH rv = block.call ensure $LOAD_PATH.shift end end return rv end |