All Projects → goyalankit → modularize_sinatra

goyalankit / modularize_sinatra

Licence: MIT license
Modularized Sinatra Skeleton Generator

Programming Languages

ruby
36898 projects - #4 most used programming language

Projects that are alternatives of or similar to modularize sinatra

api
Tendrl API
Stars: ✭ 16 (-33.33%)
Mutual labels:  sinatra
ruby-whatsapp-bots
A repo of WhatsApp bots built in Ruby
Stars: ✭ 18 (-25%)
Mutual labels:  sinatra
em-shorty
Another URL shortener based on Event Machine and rack-fiber_pool
Stars: ✭ 56 (+133.33%)
Mutual labels:  sinatra
gitlab-live
Interactive online shell for GitLab API
Stars: ✭ 21 (-12.5%)
Mutual labels:  sinatra
pifi-radio
MPD web client to listen to radio, written in React and Sinatra.
Stars: ✭ 36 (+50%)
Mutual labels:  sinatra
react-sinatra
React on Sinatra Integration, Server Side Rendering
Stars: ✭ 43 (+79.17%)
Mutual labels:  sinatra
sickbay
Get the HTTP status of a bunch of URLs in a single JSON response. Ideal for monitoring a lot of services at once.
Stars: ✭ 19 (-20.83%)
Mutual labels:  sinatra
cchecksapi
CRAN checks API
Stars: ✭ 34 (+41.67%)
Mutual labels:  sinatra
presley
Presley - A lightweight web framework for Windows
Stars: ✭ 26 (+8.33%)
Mutual labels:  sinatra
ruby-sinatra-starter-app
A starter project for Ruby On Sinatra web app projects to introduce programmers to Ruby programming.
Stars: ✭ 36 (+50%)
Mutual labels:  sinatra
sinatra-dev-cheatsheet
A quick-and-dirty cheat sheet for creating HTML/CSS websites, and developing using Sinatra and ActiveRecord.
Stars: ✭ 44 (+83.33%)
Mutual labels:  sinatra
veterinary-list-api
Veterinary List REST API
Stars: ✭ 18 (-25%)
Mutual labels:  sinatra
sinatras-skeleton
Basic Sinatra Skeleton MVC CRUD App with Sprockets, Warden, ActiveRecord and PostgresQL
Stars: ✭ 13 (-45.83%)
Mutual labels:  sinatra
rack-cargo
🚚 Batch requests for Rack apps (works with Rails, Sinatra, etc)
Stars: ✭ 17 (-29.17%)
Mutual labels:  sinatra
coordinator-bot
A tutorial that builds a simple bot for Facebook Messenger with Ruby and Sinatra
Stars: ✭ 16 (-33.33%)
Mutual labels:  sinatra
rubynepal.github.io
Official website of Ruby Nepal
Stars: ✭ 21 (-12.5%)
Mutual labels:  sinatra
encrypted cookie
AES-128 encrypted session cookies for Rack (and Sinatra and other frameworks).
Stars: ✭ 54 (+125%)
Mutual labels:  sinatra
darrrr
An SDK for the delegated recovery specfication
Stars: ✭ 43 (+79.17%)
Mutual labels:  sinatra
sinator
Sinatra application generator
Stars: ✭ 19 (-20.83%)
Mutual labels:  sinatra
kaminari-sinatra
Kaminari Sinatra adapter
Stars: ✭ 26 (+8.33%)
Mutual labels:  sinatra

Modularize Sinatra

Gem Version

Modularized Code Generator for Sinatra. Gem available on rubygems More information at: http://goyalankit.com/blog/2013/07/23/modularize-sinatra/

Installation

$ gem install modularize_sinatra

Usage

To generate the skeleton structure with custom controller:

modularize_sinatra new myapp -C user

To Start the app:

rackup -p 9292

It will generate a default index page for you, which can be accessed at:

http://localhost:9292/

You'll get the following directory structure with above command:

    .
    ├── config
    │   └── environment.rb
    ├── lib
    │   ├── controllers
    │   │   └── user.rb
    │   ├── views
    │   │   └── users
    │   │       └── index.erb
    │   └── app.rb
    ├── spec
    │   ├── controllers
    │   │   └── user_spec.rb
    │   └── spec_helper.rb
    ├── Gemfile
    ├── Rakefile
    ├── config.ru
    └── myapp.rb

Without the -C paramter( not recommended ), it will generate a default controller for you called Ping and will create the following route:

GET http://localhost:9292/ping
> Ahoy! from Myapp 2013-04-07 00:33:58 +0530

Currently rspec is configured by default. Hope to release support for other frameworks in future versions.

To Run specs:

bundle exec rake 

Contributing

  1. Fork it
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Added some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create new Pull Request
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].