...
- Set up git remote targets. At least one must point to apache.org. For example, you may set origin to point to the Apache git server for -core repository.
...
2. Have a clean, up-to-date version of -core (or -newt or -newtmgr depending on which repository you are working with) with master branch checked out.
git pull --rebase origin master
3. Bring in the pull request (PR) you want to merge. The <branch-name> is the branch in the GitHub user's fork where the code additions or modifications have been made.
git pull https://github.com/<github-username>/incubator-mynewt-core <branch-name>
The commit message for the merge comes up in edit mode. Add the following line to the message to tell GitHub to close the PR upon merge.
"This closes #<PR number>"
4. Push the change to apache’s git repository. In the example below you are pushing it to the "master" branch.
$ git push origin master
5. The GitHub mirror picks up the merge and updates the PR status in a few seconds.