I suppose what I could do is build according to a convention in Padrino that I know would work well in Rails, then when the time comes, write some scripts to transform the codebase. Probably a job for Rake.
Really though, I can't see much of a benefit over just starting with Rails. I might try it once just to confirm.
A new framework would have to do something for me that both Rails and Sinatra won't.
Ah well, I don't think there actually is such a use case. I thought maybe because I once started a project with Sinatra that I later wished I'd built with Rails.
Really it seems to boil down to what the application is supposed to be doing. If it's primarily something else that just maybe speaks HTTP, like a microservice, then Sinatra is the more flexible choice, you can encapsulate the web logic and build your own abstractions as you see fit.
If it's primarily a website, then you'll want a full-fledged batteries-included framework.
Projects don't start as a microservice and evolve into a website. The one project I started with Sinatra should have been Rails from the beginning, as it was really a website. I just used Sinatra because at the time I knew it better.
You can cherry pick parts of it out in to a Sinatra app, or you can swap out `Sinatra::Application` for `Padrino::Application`.
Hanami seems to be inspired by Uncle Bob's Clean Architecture. IMO it's pretty nicely done and a good example of how Clean Arch can be implemented. Worth playing with if only to get a feel for it's structure and potentially influence your Rails apps.
What would be really awesome is a way to 'promote' projects. Currently, if I start a Sinatra project and I realize later that I needed Rails, I've no choice but to either re-engineer the entire project, or tough it out with Sinatra.
If I had an upgrade path, then I could start every project off in Sinatra, then when I start finding myself wanting more functionality, fluidly migrate to Hanami or Rails.