Sha256: d998fdfb8460c0e273ddc9e90d7d71ff3ab3c2051061c63fab7d857dbccbcbf1
Contents?: true
Size: 1.5 KB
Versions: 3
Compression:
Stored size: 1.5 KB
Contents
require "active_support/all" require "digest/md5" require "eeepub" require "erb" require "logger" require "nokogiri" require "notifier" require "open3" require "optparse" require "ostruct" require "RedCloth" require "tempfile" require "pathname" require "thor" require "thor/group" require "yaml" require "cgi" %w[maruku peg_markdown bluecloth redcarpet rdiscount].each do |lib| begin require lib break rescue LoadError => e next end end Encoding.default_internal = "utf-8" Encoding.default_external = "utf-8" module Bookshelf require "bookshelf/extensions/string" require "bookshelf/extensions/redcloth" require "bookshelf/errors" ROOT = Pathname.new(File.dirname(__FILE__) + "/..") autoload :Version, "bookshelf/version" autoload :Generator, "bookshelf/generator" autoload :TOC, "bookshelf/toc" autoload :Cli, "bookshelf/cli" autoload :Markdown, "bookshelf/adapters/markdown" autoload :Parser, "bookshelf/parser" autoload :Exporter, "bookshelf/exporter" autoload :Syntax, "bookshelf/syntax" autoload :Stream, "bookshelf/stream" autoload :Dependency, "bookshelf/dependency" autoload :Stats, "bookshelf/stats" def self.config path = Pathname.new("config/config.yml") content = File.read(path) erb = ERB.new(content).result YAML.load(erb).with_indifferent_access end def self.logger @logger ||= Logger.new(File.open("/tmp/bookshelf.log", "a")) end def self.root_dir @root_dir ||= Pathname.new(Dir.pwd) end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
bookshelf-1.2.1 | lib/bookshelf.rb |
bookshelf-1.2.0 | lib/bookshelf.rb |
bookshelf-1.1.0 | lib/bookshelf.rb |