Sha256: f57f6b4d102f098ff49c4061100e6c688af482a7bfe1c34e74182cf37061de4d

Contents?: true

Size: 838 Bytes

Versions: 8

Compression:

Stored size: 838 Bytes

Contents

require "thor"
require "thor/group"

module Middleman::Templates
  @@template_mappings = {}
  def self.register(name, klass)
    @@template_mappings[name] = klass
  end
  
  def self.registered_names
    @@template_mappings.keys
  end
  
  def self.registered_templates
    @@template_mappings
  end
  
  class Base < ::Thor::Group
    include Thor::Actions
    
    argument :location, :type => :string
    class_option :template, :default => "default"
    class_option :css_dir, :default => "stylesheets"
    class_option :js_dir, :default => "javascripts"
    class_option :images_dir, :default => "images"
  end
end

# Default template
require "middleman/templates/default"

# Blog template
require "middleman/templates/blog"

# HTML5 template
require "middleman/templates/html5"

# Local templates
require "middleman/templates/local"

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
middleman-2.0.0.rc99 lib/middleman/templates.rb
middleman-2.0.0.rc98 lib/middleman/templates.rb
middleman-2.0.0.rc97 lib/middleman/templates.rb
middleman-2.0.0.rc96 lib/middleman/templates.rb
middleman-2.0.0.rc95 lib/middleman/templates.rb
middleman-2.0.0.rc93 lib/middleman/templates.rb
middleman-2.0.0.rc92 lib/middleman/templates.rb
middleman-2.0.0.rc91 lib/middleman/templates.rb