lib/webby/builder.rb in webby-0.7.0 vs lib/webby/builder.rb in webby-0.7.1
- old
+ new
@@ -1,6 +1,6 @@
-# $Id: builder.rb 60 2007-12-04 05:05:50Z tim_pease $
+# $Id: builder.rb 92 2008-01-03 19:41:51Z tim_pease $
require 'find'
require 'fileutils'
require 'erb'
@@ -37,10 +37,10 @@
tmpl = opts[:from]
raise Error, "template not given" unless tmpl
raise Error, "#{page} already exists" if test ?e, page
Logging::Logger[self].info "creating #{page}"
- FileUtils.mkdir_p File.dirname(page)
+ FileUtils.mkdir_p ::File.dirname(page)
str = ERB.new(::File.read(tmpl), nil, '-').result
::File.open(page, 'w') {|fd| fd.write str}
return nil
end