Git - merge investigation
1. How to find out if branch has been merged into your current branch 2. How to find out if your current branch has been merged into any other branch 1. To check if a feature or branch has been merged into your current branch , use the git branch --merged command, the git merge-base command, or inspect the git log. Methods to Verify a Merge: 1. Using git branch --merged This command lists all branches whose tips are reachable from your current branch's HEAD, meaning they are fully integrated. First, ensure you are on the branch where you expect the feature to be merged (e.g., main): git checkout <current-branch-name> Then, run the command to list all merged branches: git branch --merged If the feature branch name appears in the output list, it has been merged into your current branch. To see branches that have not been merged, you can use the --no-merged flag instead: git branch --no-merged 2. Using git merge-base This method determines the common anc...