Sha256: 451bb29dd628c4d4f159336e14dc9a71e0da93b5e00caf9c2d57d036e9f6e67f
Contents?: true
Size: 604 Bytes
Versions: 29
Compression:
Stored size: 604 Bytes
Contents
require 'active_support' require 'active_support/core_ext' require 'thor' require 'eucalypt/helpers' module Eucalypt module Generators class Helper < Thor::Group include Thor::Actions include Eucalypt::Helpers def self.source_root File.join File.dirname(__dir__), 'templates' end def generate(spec: true, name:) helper = Inflect.new(:helper, name) config = {class_name: helper.class_name} template("helper.tt", helper.file_path, config) template("helper_spec.tt", helper.spec_path, config) if spec end end end end
Version data entries
29 entries across 29 versions & 1 rubygems