Sha256: 2d87f8475378e0464be2e0b46d9b1b8535b6f0900c4e55ed01caa77b173bc371

Contents?: true

Size: 853 Bytes

Versions: 1

Compression:

Stored size: 853 Bytes

Contents

#
# Murdoc is *yet another* Doccu-like documentation generator.
# Murdoc reads ruby source files and produces annotated html documentation.
#
# See also: [Docco][do], [Rocco][ro]
#
# [do]: "http://jashkenas.github.com/docco/"
# [ro]: "http://rtomayko.github.com/rocco"
#


module Murdoc
  def self.generate_from_file(input, output, options = {})
    annotator = Annotator.from_file(input, nil, options)
    markup_dir = File.dirname(__FILE__)+ "/../markup"
    File.open(output, "w+") do |f|
      f.puts Formatter.new("#{markup_dir}/template.haml").render(:paragraphs => annotator.paragraphs, :stylesheet => File.read("#{markup_dir}/stylesheet.css"))
    end
  end
end

require "murdoc/annotator"
require "murdoc/paragraph"
require "murdoc/formatter"

Dir["#{File.dirname(File.expand_path(__FILE__))}/murdoc/languages/*.rb"].each {|lang| require lang }

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
murdoc-0.1.1 lib/murdoc.rb