summaryrefslogtreecommitdiffstats
path: root/lib/puppet/util/autoload.rb
diff options
context:
space:
mode:
authorRick Bradley <rick@rickbradley.com>2007-10-04 08:04:44 -0500
committerRick Bradley <rick@rickbradley.com>2007-10-04 08:04:44 -0500
commit92d23e0398ffbaf7e264bb7ff716bd6f83130b07 (patch)
treeaf4a9296a11733c4636a88d38925804ea6f0793d /lib/puppet/util/autoload.rb
parent1334b786ac622a6094ba68b3e66fce3f5841deed (diff)
parentbd8e38236a23ae687c418fcbb90e5f61c8c67b01 (diff)
downloadpuppet-92d23e0398ffbaf7e264bb7ff716bd6f83130b07.tar.gz
puppet-92d23e0398ffbaf7e264bb7ff716bd6f83130b07.tar.xz
puppet-92d23e0398ffbaf7e264bb7ff716bd6f83130b07.zip
Merge branch 'master' of git://reductivelabs.com/puppet into routing
Diffstat (limited to 'lib/puppet/util/autoload.rb')
-rw-r--r--lib/puppet/util/autoload.rb9
1 files changed, 2 insertions, 7 deletions
diff --git a/lib/puppet/util/autoload.rb b/lib/puppet/util/autoload.rb
index 280961837..a52575522 100644
--- a/lib/puppet/util/autoload.rb
+++ b/lib/puppet/util/autoload.rb
@@ -107,16 +107,11 @@ class Puppet::Util::Autoload
# Load every instance of everything we can find.
eachdir do |dir|
Dir.glob("#{dir}/*.rb").each do |file|
- # Load here, rather than require, so that facts
- # can be reloaded. This has some short-comings, I
- # believe, but it works as long as real classes
- # aren't used.
name = File.basename(file).sub(".rb", '').intern
next if loaded?(name)
- next if $".include?(File.join(@path, name.to_s + ".rb"))
- filepath = File.join(@path, name.to_s + ".rb")
+ rubypath = File.join(@path, name.to_s)
begin
- Kernel.require file
+ Kernel.require rubypath
loaded(name, file)
rescue => detail
if Puppet[:trace]