Sha256: 365cd459a6c562c91e217d686455625257df906a482a2ef9cabef92f704f6c2c
Contents?: true
Size: 516 Bytes
Versions: 1
Compression:
Stored size: 516 Bytes
Contents
module Chatterbot # # bot template generator class Skeleton class << self # # generate a template file for the specified bot # @param [Bot] bot object # def generate(bot) path = File.join(Chatterbot.libdir, "..", "templates", "skeleton.txt") src = File.read(path) opts = bot.config.merge({ :name => bot.botname, :timestamp => Time.now }) puts opts.inspect src % opts end end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
chatterbot-2.0.0.pre | lib/chatterbot/skeleton.rb |