diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index c426b8d0..9ee050cd 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -13,16 +13,12 @@ request. 1. Now that you've cloned the repo, navigate to it and install dependencies by running: - ``` - bundle install - ``` + bundle install 1. All tests should be passing, but it's a good idea to run them anyway before starting any work: - - ``` - bundle exec rake - ``` + + bundle exec rake 1. If you're adding functionality or fixing a bug, you'll want to add a failing test for the issue first. @@ -33,34 +29,42 @@ request. run the tests again. Since you're probably working on a single file, you can run the tests for that file with the following command: - ``` - appraisal 4.2 rspec - ``` + bundle exec appraisal rspec - You can also run unit tests by running `zeus start` in one shell, and then - running the following in another: + You can find a list of valid Appraisals by running: - ``` - zeus rspec - ``` + bundle exec rake appraisal:list - And to run the entire test suite again: - - ``` - bundle exec rake - ``` + (If you're familiar with Zeus, you can also run unit tests by running `zeus + start` in one shell, and then running the following in another:) + + zeus rspec + + In any case, to run the entire test suite again, say: + + bundle exec rake 1. Finally, push to your fork and submit a pull request. -At this point you're waiting on us. We try to respond to issues and pull -requests within a few business days. We may suggest some changes to make to your -code to fit with our [code style] or the project style, or discuss alternate -ways of addressing the issue in question. When we're happy with everything, -we'll bring your changes into master. Now you're a contributor! +At this point, you're waiting on us. We may suggest some changes to make to your +code to fit within the project style, or discuss alternate ways of addressing +the issue in question. When we're happy with everything, we'll bring your +changes into master. Now you're a contributor! ## Addendum: Setting up your environment -### Installing dependencies (Linux only) +### Installing Ruby + +shoulda-matchers is only compatible with Ruby 2.x. A `.ruby-version` is included +in the repo, so if you're using one of the Ruby version manager tools, then you +should be using (or have been prompted to install) the latest version of Ruby. +If not, you'll want to do that. + +[working Ruby environment]: #addendum-setting-up-your-environment +[Code of Conduct]: https://thoughtbot.com/open-source-code-of-conduct +[execjs]: https://github.com/sstephenson/execjs + +### Linux-specific instructions #### Debian/Ubuntu @@ -86,16 +90,3 @@ sudo su curl -sL https://rpm.nodesource.com/setup | bash - yum install -y nodejs ``` - -### Installing Ruby (all platforms) - -shoulda-matchers is only compatible with Ruby 2.x. A `.ruby-version` is included -in the repo, so if you're using one of the Ruby version manager tools, then you -should be using (or have been prompted to install) the latest version of Ruby. -If not, you'll want to do that. - -[working Ruby environment]: #addendum-setting-up-your-environment -[Code of Conduct]: https://thoughtbot.com/open-source-code-of-conduct -[code style]: https://github.com/thoughtbot/guides/tree/master/style -[execjs]: https://github.com/sstephenson/execjs -[install rvm]: https://rvm.io/rvm/install diff --git a/Rakefile b/Rakefile index 890c2829..411c8e1b 100644 --- a/Rakefile +++ b/Rakefile @@ -34,6 +34,13 @@ task :default do end end +namespace :appraisal do + task :list do + appraisals = Tests::CurrentBundle.instance.available_appraisals + puts "Valid appraisals: #{appraisals.join(', ')}" + end +end + Shoulda::Matchers::DocumentationTasks.create task release: 'docs:publish_latest'