lib/runeblog.rb in runeblog-0.3.02 vs lib/runeblog.rb in runeblog-0.3.03
- old
+ new
@@ -120,10 +120,11 @@
self.class.blog = self # Weird. Like a singleton - dumbass circular dependency?
@root = Dir.pwd/root_rel
write_repo_config(root: @root) # ?? FIXME
get_repo_config
+ read_features # top level
@views = retrieve_views
self.view = File.read(@root/"data/VIEW").chomp
md = Dir.pwd.match(%r[.*/views/(.*?)/])
if md
@view_name = md[1]
@@ -292,14 +293,16 @@
when "[no view]"
# puts "Warning: No current view set"
@view = nil
when RuneBlog::View
@view = arg
+ read_features(@view)
_set_publisher
when String
new_view = str2view(arg)
raise NoSuchView(arg) if new_view.nil?
@view = new_view
+ read_features(@view)
_set_publisher
else
raise CantAssignView(arg.class.to_s)
end
rescue => err