Skip to content

Latest commit

 

History

History
58 lines (45 loc) · 2.08 KB

CONTRIBUTING.md

File metadata and controls

58 lines (45 loc) · 2.08 KB

Contributing

Running tests

bundle
psql -h localhost -c 'CREATE DATABASE safe_pg_migrations_test'
rake test

You may want to use one of the specific gemfiles, to test against some exotic setups. To do so, run:

BUNDLE_GEMFILE=gemfiles/<YOUR GEMFILE> bundle
BUNDLE_GEMFILE=gemfiles/<YOUR GEMFILE> bundle exec rake test

Releasing

Automatic release message

Automatic release message can be generated using GitHub's release tool. It is configured via .github/release.yml.

  • Any pull request merged with labels ignore-for-release or dependencies will be ignored.
  • Pull requests released with label breaking-change will be gathered in the "Breaking changes" section.
  • Pull requests released with label bug will be gathered in the "Bug fixes" section.
  • Any other release will be added to the "New features" section.

Release process


NOTE

You need to be part of Doctolib to release a new version of this gem.


  1. Create a pull request and update the tag:
      vim lib/safe-pg-migrations/version.rb # Or whatever editor you'd like
      bundle # to update the gem version in Gemfile.lock
  2. Pull master on your computer, and generate the new gem file:
    bundle
    gem build safe-pg-migrations.gemspec
    # This pushed the new gem version to RubyGem.  You will probably be asked your TOTP code at this step
    gem push safe-pg-migrations-<VERSION>.gem
  3. Once the pull request is merged, create a new release on GitHub.
    1. Click on GitHub's release tool;
    2. Click on "Choose a tag" and write the name of your new tag (using semantic versioning). A button will appear to create the new tag;
    3. Once the tag is created, feel the release title with your tag name as well;
    4. Click on "Generate release notes"
    5. Ensure that "Set as the latest release" is checked
    6. Upload the gem file you generated in step 2
    7. Click on "Publish release"