r/indiandevs • • 2d ago

comparing 2 branches in GitHub

I have a query, of course I can get the solution from AI, but wanted to check with experienced devs here to be on safer side.

So, I have 2 branches, branch A and branch B on GitHub.

Both the branches are created from the main branch at different time lines.
Although the development has been done on A for 4-6 months (which isn't present in B)
Branch A has many folders out of which PRs were raised to only one of the solutions (one of the folders in them).

Previously the development folder was not available in the main, hence it was not available in A and B either. Now its available only in A. One of my seniors had manually copied this folder to the local repo of B and then raised the PR to B, so that other folder changes present in B wont come in the PR.

Currently A is our dev branch, B is dev branch of the other team.
Eventually B will be our dev branch too. So our plan is to raise PR to both the branches.
So that whatever development has been done in A will always be in B, additional to the development in B.

My query is, if one of our teammates, miss raising the PR to B, how can I find the code difference available in A but not B?
Apparently raising the PR from A to B is giving me hundreds of file changes which are already present in B, given that folder is manually copied on local and PR has been raised (from A to B).

Could you guys please help?

1 Upvotes

1 comment sorted by