views:

390

answers:

2

How do I set global configuration for RSpec in Ubuntu.

Specifically so, --color and --format specdoc stay turned on, across all my projects (ie every time I run rspec anywhere).

+1  A: 

If you use rake to run rspec tests then you can edit spec/spec.opts

http://rspec.info/rails/runners.html

fernyb
I've been looking for this information everywhere. Thanks :)
Stephen Eilert
./spec.opts has been depricated. Rails 3 wants the file to be named ./.rspec or ~/.rspec
Aaron Wheeler
+2  A: 

Or simply add alias spec=spec --color --format specdoc to your ~/.bashrc file like me.

zzeroo