From: Michael Orlitzky Date: Fri, 21 Nov 2008 22:01:32 +0000 (-0500) Subject: I take that last commit back. Now the relative include path issue is fixed. The previ... X-Git-Url: https://gitweb.michael.orlitzky.com/?a=commitdiff_plain;h=75222ee5b6ebd3b625f35d5109d082159d84e537;p=dead%2Fwhatever-dl.git I take that last commit back. Now the relative include path issue is fixed. The previous commit fails to include all of the website classes since the Dir.glob method doesn't necessarily (usually) look in the correct place. --- diff --git a/bin/whatever-dl b/bin/whatever-dl index 79cbbee..99183f6 100755 --- a/bin/whatever-dl +++ b/bin/whatever-dl @@ -36,9 +36,14 @@ $: << File.dirname(executable) + '/../' require 'src/uri_utilities' +# The Dir.glob that's coming up doesn't use the +# Ruby library path so we need to tell it where to +# look explicitly. +websites_pattern = File.dirname(executable) + '/../src/websites/*.rb' + # All of the website classes are located in one # directory, so we can 'require' them automatically. -Dir.glob('src/websites/*.rb').each do |r| +Dir.glob(websites_pattern).each do |r| require r end