Sha256: 0762f30b0d6620aa6a92259f5c2e0229f386bf54dd22f2f9db8b37e44bb6c082
Contents?: true
Size: 534 Bytes
Versions: 1
Compression:
Stored size: 534 Bytes
Contents
module Sinatra class NameCommand < Sinatra::Command include FileUtils attr_accessor :args, :name def self.inherited(klass) Command.inherited(klass) end def underscored self.name.underscore end def classified self.name.classify end def initialize(args) self.args = args self.name = ARGV[1] end def clean_string(f) f.gsub(Sinatra.template_dir, @app_dir).gsub("template_app", self.underscored).gsub("TemplateApp", self.classified) end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
sinatra-template-1.2.0 | lib/sinatra/commands/name_command.rb |