Synchronizing your activities in GitHub projects
If GitHub synchronization has been enabled by the administrator, the following user activities will be synchronized between Github and Upsource:
- Discussion comments posted in GitHub will be shown in Upsource and vice-versa
- Pull requests are recognized and can be created right from Upsource
- A branch review will be automatically created on a new pull request
A GitHub icon on the project home page means Upsource recognises you as a GitHub user:
![github synch icon github synch icon](https://resources.jetbrains.com/help/img/upsource/2017.3/github_synch_icon.png)
If you are not recognized, click Login to GitHub:
![login to github login to github](https://resources.jetbrains.com/help/img/upsource/2017.3/login_to_github.png)
Now you can merge branches, create and close pull requests from Upsource, and the comments you make in Upsource will be posted in GitHub as well.
Pull requests and merges
When a new branch is created along with a pull request in GitHub, Upsource automatically creates a branch review for it. After reviewing and accepting the changes you can merge the branch without leaving Upsource:
![git sync merge git sync merge](https://resources.jetbrains.com/help/img/upsource/2017.3/git_sync_merge.png)
If you decide to reject the pull request and not merge the branch, you can close the review — the pull request will then be closed in GitHub as well.
If the branch has conflicts with the base branch and cannot be merged automatically, a corresponding message will be displayed in place of the Merge button:
![git sync conflict git sync conflict](https://resources.jetbrains.com/help/img/upsource/2017.3/git_sync_conflict.png)
If the branch has been created without a pull request, you may create a pull request right from Upsource:
![git sync pullrequest git sync pullrequest](https://resources.jetbrains.com/help/img/upsource/2017.3/git_sync_pullrequest.png)
Click Create pull request.
In the displayed dialog window, enter your pull request title and select the base branch.
Click Create.
In addition to the pull request, a branch review will be created and the branch revisions included in it.