'git - rebase a pull request without affecting merge commit history

I have a feature branch called branch_1. I made some changes to this branch and then created a pull request. Upon getting feedback I made the changes and updated the PR.

I need to rebase branch_1 with the updated master in order for tests to pass in order to merge. I used the following command to rebase. git rebase master There are x pull and y push between origin and local. How do I push the updated rebase branch_1 without affecting the commit history of my PR?



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source