vertmac / designmodo-startup_framework-rails

A gem to integrate designmodo Startup Framework in Rails
BSD 2-Clause "Simplified" License
36 stars 5 forks source link

Invalid Startup Framework directory (RuntimeError) #8

Open akeelahmedqureshi opened 9 years ago

akeelahmedqureshi commented 9 years ago

abc@abc:~/startupfw-rails$ rails generate startup_framework:install /home/cis/Downloads/StartupFramework /home/cis/.rvm/gems/ruby-2.1.2/gems/designmodo-startup_framework-rails-1.1.3.10/lib/generators/startup_framework/install/install_generator.rb:44:in copy_assets': Invalid Startup Framework directory (RuntimeError) from /home/cis/.rvm/gems/ruby-2.1.2/gems/thor-0.19.1/lib/thor/command.rb:27:inrun' from /home/cis/.rvm/gems/ruby-2.1.2/gems/thor-0.19.1/lib/thor/invocation.rb:126:in invoke_command' from /home/cis/.rvm/gems/ruby-2.1.2/gems/thor-0.19.1/lib/thor/invocation.rb:133:inblock in invoke_all' from /home/cis/.rvm/gems/ruby-2.1.2/gems/thor-0.19.1/lib/thor/invocation.rb:133:in each' from /home/cis/.rvm/gems/ruby-2.1.2/gems/thor-0.19.1/lib/thor/invocation.rb:133:inmap' from /home/cis/.rvm/gems/ruby-2.1.2/gems/thor-0.19.1/lib/thor/invocation.rb:133:in invoke_all' from /home/cis/.rvm/gems/ruby-2.1.2/gems/thor-0.19.1/lib/thor/group.rb:232:indispatch' from /home/cis/.rvm/gems/ruby-2.1.2/gems/thor-0.19.1/lib/thor/base.rb:440:in start' from /home/cis/.rvm/gems/ruby-2.1.2/gems/railties-4.1.6/lib/rails/generators.rb:157:ininvoke' from /home/cis/.rvm/gems/ruby-2.1.2/gems/railties-4.1.6/lib/rails/commands/generate.rb:11:in <top (required)>' from /home/cis/.rvm/gems/ruby-2.1.2/gems/activesupport-4.1.6/lib/active_support/dependencies.rb:247:inrequire' from /home/cis/.rvm/gems/ruby-2.1.2/gems/activesupport-4.1.6/lib/active_support/dependencies.rb:247:in block in require' from /home/cis/.rvm/gems/ruby-2.1.2/gems/activesupport-4.1.6/lib/active_support/dependencies.rb:232:inload_dependency' from /home/cis/.rvm/gems/ruby-2.1.2/gems/activesupport-4.1.6/lib/active_support/dependencies.rb:247:in require' from /home/cis/.rvm/gems/ruby-2.1.2/gems/railties-4.1.6/lib/rails/commands/commands_tasks.rb:135:ingenerate_or_destroy' from /home/cis/.rvm/gems/ruby-2.1.2/gems/railties-4.1.6/lib/rails/commands/commands_tasks.rb:51:in generate' from /home/cis/.rvm/gems/ruby-2.1.2/gems/railties-4.1.6/lib/rails/commands/commands_tasks.rb:40:inrun_command!' from /home/cis/.rvm/gems/ruby-2.1.2/gems/railties-4.1.6/lib/rails/commands.rb:17:in <top (required)>' from /home/cis/.rvm/gems/ruby-2.1.2/gems/activesupport-4.1.6/lib/active_support/dependencies.rb:247:inrequire' from /home/cis/.rvm/gems/ruby-2.1.2/gems/activesupport-4.1.6/lib/active_support/dependencies.rb:247:in block in require' from /home/cis/.rvm/gems/ruby-2.1.2/gems/activesupport-4.1.6/lib/active_support/dependencies.rb:232:inload_dependency' from /home/cis/.rvm/gems/ruby-2.1.2/gems/activesupport-4.1.6/lib/active_support/dependencies.rb:247:in require' from /home/cis/startupfw-rails/bin/rails:8:in<top (required)>' from /home/cis/.rvm/gems/ruby-2.1.2/gems/activesupport-4.1.6/lib/active_support/dependencies.rb:241:in load' from /home/cis/.rvm/gems/ruby-2.1.2/gems/activesupport-4.1.6/lib/active_support/dependencies.rb:241:inblock in load' from /home/cis/.rvm/gems/ruby-2.1.2/gems/activesupport-4.1.6/lib/active_support/dependencies.rb:232:in load_dependency' from /home/cis/.rvm/gems/ruby-2.1.2/gems/activesupport-4.1.6/lib/active_support/dependencies.rb:241:inload' from /home/cis/.rvm/rubies/ruby-2.1.2/lib/ruby/2.1.0/rubygems/core_ext/kernel_require.rb:55:in require' from /home/cis/.rvm/rubies/ruby-2.1.2/lib/ruby/2.1.0/rubygems/core_ext/kernel_require.rb:55:inrequire' from -e:1:in `

'

kevinrivers commented 9 years ago

At the bottom is the snippet checking for a valid Startup Framework directory. Based on my experience the directory is unpacked as: "Startup Framework" so your command should be:

/home/cis/Downloads/Startup\ Framework

Tab complete is your friend here.

@ui-kit = "ui-kit"
...

if File.directory?(File.join(@pro_dir, "Developer"))
  @pro_dir = File.join(@pro_dir, "Developer")
end
unless File.directory?(@pro_dir) && File.directory?(File.join(@pro_dir, @ui_kit))
  raise "Invalid Startup Framework directory"
end