Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Fork the ASF repo

$ git clone https://git-wip-us.apache.org/repos/asf/incubator-quickstep.git quickstep

$ cd quickstep

Work on a new feature

// Create a JIRA ticket at https://issues.apache.org/jira/browse/QUICKSTEP, say QUICKSTEP-101.

$ git checkout master

$ git checkout -b my-awesome-feature

$ git add some-changed-or-new-files

$ git commit -m "QUICKSTEP-101: Added My Awesome Feature."

$ git push origin my-awesome-feature

 

// Sometime we may have code review comments after opening a PR.

$ git add more-changed-or-new-files

$ git commit -m "Addressed Review Comments."

 

// Finally, once the PR are ready to merge (i.e., passing all the CI tests),

// we have to squash all the commits into one. We cherry pick the first commit,

// and squash all the rest.

$ git rebase -i origin/master

// In the editor, we would see

//   QUICKSTEP-101: pick Added My Awesome Feature.

//   pick Addressed Review Comments.

// And we need to modify all the content (except to the first line) to "s Addressed Review Comments.".

 

// Check "Author" field with the intended name and email. Amend them if necessaryneeded.

$ git log

 

$ git push origin my-awesome-feature -f

Create a PR for the new feature

Use the GitHub ASF mirror repo: https://github.com/apache/incubator-quickstep, and set the title with the JIRA ticket.

In this case, QUICKSTEP-101: Added My Awesome Feature.

Merge a PR

// Update the local fork with the new branch my-awesome-feature.
$ git fetch origin
$ git checkout master

...