Thor script to generate a skeleton Sinatra application
I love Sinatra and the minimalist philosophy it embodies.
However, I felt that frameworks like Monk or Padrino take away from that minimalist feel.
So I created a script using Thor that generates a very minimal Sinatra application.
This Thor script will generate a minimalist Sinatra application.
The application that is generated includes the following Gems:
And sets up the following front-end frameworks
Finally, the script will automatically install gems via Bundler and initialize a Git repository.
Clone the repository to your local machine:
git clone https://github.com/jeffharrington/sinatra-thor.git
Change to the directory of the project and run:
thor install sinatra.thor
After going through the installation process, you will now see the task installed when you run:
thor installed
Execute the script using Thor as follows:
thor sinatra:generate YOUR_APPLICATION_NAME
This will generate a new Sinatra application with the following folder structure:
- config/
- unicorn.rb
- public/
- css/
- application.css
- js/
- application.js
- css/
- views/
- layouts/
- application.erb
- index.erb
- layouts/
- .gitignore
- app.rb
- config.ru
- environment.rb
- Gemfile
- Procfile
##License
The MIT License (MIT)
Copyright (c) 2013 Jeffrey Harrington, [email protected]