Llamarada

Tomar de la élite lo que pertenece a todos

Use Shotgun to Speed Up Your Development

| Comments

You should be using shotgun to speed up your development, instead of killing your web app server everytime you want to reload code changes into webrick, mongrel or any other rack compliant server you could be using shotgun and have it watch your files for changes and reload the code automatically

Install the shotgun gem
1
$   gem install shotgun

That is it! Now launch your shotgun app server:

fire shotgun
1
2
$   cd my_app
$   shotgun

This will launch shotgun with the default settings:

  • Listen only on **http://127.0.0.1:9393**
  • Run on development environment
  • Look for config.ru on the current directory

Now lets say you want to use something like 192.168.0.3:3000 using the production environment

customize shotgun params
1
$   shotgun -E production -o 192.168.0.3 -p 3000
  • -E lets you set the environment
  • -o configures the address the server will bind to
  • -p sets the port the server will bind to

happy hacking

Comments