I have a ruby on rails application which should be gem-ified. Jeweler, helps to create basic rubigems. However, how do I package the rails app as a gem? I have a main application that requires my rails application as a gem. I can’t integrate them, since the main rails application should be used as a management application for managing small applications that work in it like gems / engines.
Since Rails 3.0, any Rails application is an engine. To wrap an application in a gem, you must:
Your lib / my_gem.rb file should contain the following code:
module MyGem class Engine < Rails::Engine; end end
UPD
Or better if you use mounted motors:
$ rails plugin new MyGem
He creates a mountable engine with a dummy test application and gemspec.