Nope. No go. The lines immediately following the padrino-gen
statements below are from some puts I've added to cli.rb:
def setup
Padrino::Generators.load_components!
puts "ARGV: #{ARGV}"
generator_kind = ARGV.delete_at(0).to_s.downcase.to_sym if
ARGV[0].present?
puts "generator_kind: #{generator_kind}"
generator_class = Padrino::Generators.mappings[generator_kind]
puts "generator_class: #{generator_class}"
if generator_class
puts "inside of generator_class call"
args = ARGV.empty? && generator_class.require_arguments? ?
["-h"] : ARGV
generator_class.start(args)
else
puts "Please specify generator to use
(#{Padrino::Generators.mappings.keys.join(", ")})"
end
end
root@sinatra:~# padrino-gen project sample_blog -t shoulda -e haml -m
mocha -s jquery -d activerecord
/var/lib/gems/1.9.1/gems/padrino-gen-0.9.10/lib
/var/lib/gems/1.9.1/gems/padrino-core-0.9.10/lib
/root
ARGV: ["project", "sample_blog", "-t", "shoulda", "-e", "haml", "-m",
"mocha", "-s", "jquery", "-d", "activerecord"]
generator_kind: project
generator_class: Padrino::Generators::Project
inside of generator_class call
create
create config/boot.rb
create config/apps.rb
create
config.ru
8<--- snip --->8
=================================================================
sample_blog is ready for development! Next, follow these steps:
=================================================================
1) cd sample_blog
2) bundle install
=================================================================
root@sinatra:~# cd sample_blog/
root@sinatra:~/sample_blog# bundle install
8<--- snip --->8
Your bundle is complete! Use `bundle show [gemname]` to see where a
bundled gem is installed.
root@sinatra:~/sample_blog# padrino-gen admin
/var/lib/gems/1.9.1/gems/padrino-gen-0.9.10/lib
/var/lib/gems/1.9.1/gems/padrino-core-0.9.10/lib
/root/sample_blog
=> Located unlocked Gemfile for development
ARGV: ["admin"]
generator_kind: admin
generator_class:
Please specify generator to use (project, app, mailer, controller,
model, migration)
root@sinatra:~/sample_blog#
Thanks for pointing out the rvms. I'll look into those as well.
-Patrick