spring-commands-any
This gem implements any of your own commands for Spring.
Usage
Add this line to your application's Gemfile:
gem 'spring-commands-any', group: :development
Insert a code to your command:
bundle exec spring binstub your-command
And then modify it not to use Spring when you run your command with bundle exec
:
begin
# load File.expand_path("../spring", __FILE__)
load File.("../spring", __FILE__) unless defined? Bundler
rescue LoadError
end
Run spring stop
and run your command:
./bin/your-command args
Also you can pass -e
or --environment=
to specify environment:
./bin/your-command args -e test
Contributing
- Fork it ( https://github.com/[my-github-username]/spring-commands-any/fork )
- Create your feature branch (
git checkout -b my-new-feature
) - Commit your changes (
git commit -am 'Add some feature'
) - Push to the branch (
git push origin my-new-feature
) - Create a new Pull Request