5.2. Contribution Procedure

We use the standard GitHub workflow for SIMP development with the exception that we use a Squash and Merge merge method for pulling in changes, in order to maintain a more legible commit history on master.

  1. Search the SIMP JIRA for an open ticket that is relevant to the issue or open a new one.

  2. Use the GitHub GUI to fork and clone the repository (we’ll use pupmod-simp-iptables for the rest of this walkthrough)

  3. Clone the repo you want to work on:

    • git clone git@github.com:<YOUR_GITHUB_NAME>/pupmod-simp-iptables iptables
  4. Enter the directory and create a feature branch: git checkout -b SIMP-XXXX

  5. Do your work! (Including tests, of course)

  6. Commit your work. We will squash your pull request into one commit when we merge it, so you can use as many commits as you’d like.

    Important

    The first commit should use the Commit Message Conventions

  7. Push your changes to Github on your feature branch:

    • git push origin SIMP-XXXX
  8. Using the GitHub GUI, create a pull request from your feature branch to the branch of the original repo that you want to contribute to. Leave the ‘Allow edits from maintainers‘ checkbox checked to let a team member add add commits to your pull request.

  9. Travis-CI will run the spec tests for the branch and a member of the SIMP team will review your submission. You should receive emails from Github as the code reviews progress.

5.2.1. Commit Message Conventions

An example commit message that following the SIMP conventions:

(SIMP-999) Fix the broken thing [50 chars max]

Discussion about the fix (if needed) [each line: 72 chars max]

SIMP-998 #comment Comment on a related issue [72 chars max]
SIMP-999 #close

The first commit message should be the following format:

  • First line:
    • Start with the Issue name in parentheses [e.g., (SIMP-999)], followed by a summary of the change
    • No longer than 50 characters
    • Followed by a line of white space
  • Subsequent lines:
    • Each line should be no longer than 72 characters
    • Describe the previous behavior, why it was changed, and the changes in detail
  • Issue references: