Padrino.load! does a recursive require in the whole ./lib folder, but normally I expect gems to take care of their own loading with the './lib/my-gem' file. Sometimes some things are left out:
Here is a case where I had some problems to share some test code.
Padrino and Bundler have a different style of subgem generation. In Pademo there are subgems named with the 'pademo-' prefix. Generating 'pademo-hello' will be:
Padrino:
./lib/pademo-hello
namespace -> pademo-hello
Bundler:
./lib/pademo/hello
namespace -> pademo::hello
The current Padrino generation matches Padrino source code style. However considering the weight of Bundler within Ruby, I am wondering if it should be considered as 'standard' practice
??? Is Padrino making assumptions on the gemified string names that depend on such style?
Using gem apps encourages other folder layout style
app/ anything internal to the app
lib/ anything that we might "require" outside the gem
assets/ non Ruby files to be shared
... because using multiple gems increase/change need of sharing resources between gems.. that can happen also through URL conventions
...TODO
In order to provide isolated independent gems, a dual configuration is needed when a Gem is loaded as part of the whole system, or as an independent Gem during development/testing
For example, this configuration code applies only to a sub-gem but cannot be placed in its './config/boot.rb' file because on production the main boot.rb file will be used, not the gem one.
Non Padrino apps like '/sinapi' (Sinatra) or '/assets' (Sprockets) are not shown with the rake routes
command
The gemspec generator depends just on padrino-core but the core gem needs full padrino while the others need the core gem (inheriting its gems)