Discussion:
calendar plugin + lib/local
Thorsten Jens
2008-01-09 12:47:54 UTC
Permalink
Hi,

I just got started using hobix (svn, revision 164). Worked pretty well
until I wanted to use the calendar plugin, 'hobix regen' complained
about

/opt/local/lib/ruby/site_ruby/1.8/hobix/out/quick.rb:124:in `load':
Error `undefined local variable or method `month' for
#<Hobix::Out::QuickArchive:0x109d778>' in erb
/Users/thodi/Sites/b/skel/monthly.html.quick-archive.
(Hobix::Out::QuickError)

I searched for this error and foun out I absolutely needed to
"'require' plugin/calendar after local". Err, OK. What? It appears
there can or must be a file called local.rb in the lib folder of my
blog to make stuff work ... but what does it have to contain?

I played with this for a while (I'm new to ruby), and when my
lib/local.rb contained

require 'hobix/out/quick'
module Hobix
class Out::QuickArchive
def month
Time.now
end
end
end

at least this error was gone. It only made way for more errors similar
to this ... days_sym was missing, offset was missing.

I' basically looking for documentation on this lib/local.rb thing and
how to make plugin/calendar.rb work.

Thodi

Loading...