docs/UPGRADING

Upgrading Standard

Since standard now encompasses both a tool itself and a series of plug-ins it makes sense to first update the standard plug-ins and then the standard tool itself. Each plug-in is a configuration for its corresponding rubocop plug-in.

The official standard plug-ins that are included in standard are:

  • Standard Performance: corresponding to rubocop-performance
  • Standard Custom: for custom cops created for standard

Updating Standard Plugins

  1. Update Rubocop plugin in the gemspec file and gem file.
  2. Keep standard in the gem file up-to-date. This will bring any testing utilities in standard into the plug-in repository.
  3. Run ./bin/rake to run the tests
  4. Configure any cops that need to be configured so that the tests pass
  5. Update the change log to the best of your ability and title it as unreleased
  6. Make your commit for these updates and push to the main branch
  7. Update the version in version.rb and update the version in the Changelog replacing the word “Unreleased”
  8. Run bundle to write the new version number to the lock file
  9. Run ./bin/rake release to release the gem to RubyGems and create the version git tag. Push the tag to GitHub.

Updating Standard

  1. Update Rubocop as well as Standard Performance in the gemspec file and gem file.
  2. Run ./bin/rake to run the tests
  3. Configure any cops that need to be configured so that the tests pass
  4. Update the change log to the best of your ability and title it as unreleased
  5. Make your commit for these updates and push to the main branch
  6. Update the version in version.rb and update the version in the Changelog replacing the word “Unreleased”
  7. Run bundle to write the new version number to the lock file
  8. Run ./bin/rake to release the gem to RubyGems and create the version git tag. Push the tag to GitHub.