Interview Prep/Git & GitHub/Merge and Rebase Problems

`warning: Cannot merge binary files: assets/logo.png (HEAD vs. feature)`

IntermediateTroubleshootingMerge and Rebase Problems
Answer

Likely causes → Both branches changed the same binary file, and Git cannot do a textual three-way merge.

Diagnose → git diff --name-only --diff-filter=U and git log --oneline main..feature -- assets/logo.png.

Fix → Pick a version: git checkout --ours assets/logo.png or --theirs, or open both versions and produce a combined one. Then git add and continue.

Prevent → Use Git LFS locking (git lfs lock) for assets that cannot be merged.

All Git & GitHub questions Roadmap: Git & GitHub

More on Merge and Rebase Problems