Sha256: 791a8c183a102a4e16fb74959528b6d3f3ebafe78408e25b0ee54a82036249c4

Contents?: true

Size: 524 Bytes

Versions: 2

Compression:

Stored size: 524 Bytes

Contents

require 'generators/cells/base'

module Apotomo
  module Generators
    class WidgetGenerator < ::Cells::Generators::Base
      source_root File.expand_path(File.join(File.dirname(__FILE__), '../templates'))
      
      def create_cell_file
        template 'widget.rb', File.join('app/widgets', class_path, "#{file_name}_widget.rb")
      end
      
      check_class_collision :suffix => "Widget"
      
      hook_for(:template_engine)
      hook_for(:test_framework)  # TODO: implement rspec-apotomo.
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
apotomo-1.1.0 lib/generators/apotomo/widget_generator.rb
apotomo-1.1.0.rc1 lib/generators/apotomo/widget_generator.rb