Understand what git merge does
Merge combines the histories of two branches into one. It creates a merge commit with two parent commits — preserving the full context of when and where branches diverged and rejoined.
# You are on feature/search, want to bring in main's latest changes
git checkout feature/search
git merge main
# Result: a new merge commit M with two parents
# * M Merge branch 'main' into feature/search
# |\
# | * c3 Add rate limiting (from main)
# * | b2 Add search endpoint (from feature/search)
# |/
# * a1 Initial commitMerge is safe on shared branches because it never rewrites existing commits — it only adds a new one.

