README.md in guard-rspec-4.5.2 vs README.md in guard-rspec-4.6.0

- old
+ new

@@ -93,10 +93,11 @@ launchy: nil # Pass a path to an rspec results file, e.g. ./tmp/spec_results.html notification: false # Display notification after the specs are done running, default: true run_all: { cmd: 'custom rspec command', message: 'custom message' } # Custom options to use when running all specs title: 'My project' # Display a custom title for the notification, default: 'RSpec results' chdir: 'directory' # run rspec from within a given subdirectory (useful if project has separate specs for submodules) +results_file: 'some/path' # use the given file for storing results (instead of default relative path) ``` ### Using Launchy to view rspec results guard-rspec can be configured to launch a results file in lieu of outputing rspec results to the terminal. @@ -105,9 +106,28 @@ ``` ruby guard :rspec, cmd: 'rspec -f html -o ./tmp/spec_results.html', launchy: './tmp/spec_results.html' do # ... end ``` + +### Using parallel_tests + +parallel_tests has a `-o` option for passing RSpec options, and here's a trick to make it work with Guard::RSpec: + +```ruby +rspec_options = { + cmd: "bundle exec rspec", + run_all: { + cmd: "bundle exec parallel_rspec -o '", + cmd_additional_args: "'" + } +} +guard :rspec, rspec_options do +# (...) +``` + +(Notice where the `'` characters are placed) + ## Development * Documentation hosted at [RubyDoc](http://rubydoc.info/github/guard/guard-rspec/master/frames). * Source hosted at [GitHub](https://github.com/guard/guard-rspec).