Start Procfile
processes in different Terminal/iTerm tabs.
I’m well aware of foreman, but it starts all processes in the same tab which can be inconvenient.
I’m well aware of tmux, but obviously not everyone’s using it (if you do, check out teamocil).
$ gem install divide
$ divide
Divide is option-free. You may however overwrite any options of your Procfile
processes by passing them to divide
.
# Procfile
web: bundle exec unicorn -c ./config/unicorn.rb
$ divide -c ./another_folder/unicorn.rb
# => bundle exec unicorn -c ./another_folder/unicorn.rb
Divide automatically loads .env
file and overwrite any $VARIABLE
of your processes.
# .env
PORT=1337
RACK_ENV=development
# Procfile
web: bundle exec unicorn -p $PORT -c ./config/unicorn.rb -E $RACK_ENV
$ divide
# => bundle exec unicorn -p 1337 -c ./config/unicorn.rb -E development
If you don’t specify a port, Divide will overwrite $PORT
with 5000.
# Procfile
web: bundle exec rails s -p $PORT
$ divide
# => bundle exec rails s -p 5000
- Add :from option
- Ignore
.env
file comments
- Always open an empty tab after all processes are executed
- iTerm opens new processes into split panes (see
85bc235
) - Make sure all the options are being replaced
- Fix bug when there are double quotes in Procfile
- iTerm.app support
- Automatically load
.env file
- Open new tabs in current directory
Why yes! You’re welcome to submit any issue or pull request as long as everything’s green when you bundle exec rake spec
. Meanwhile, you can give these folks a tap on the back for helping out:
Copyright © 2013 Etienne Lemay. See LICENSE for details.