mirror of
https://github.com/mike-rambil/Advanced-Git.git
synced 2025-12-30 14:09:30 -06:00
588 B
588 B
⬅️ Back to Sharing Changes as Patch Files
⬆️ Previous Step: Apply Diff File
Patch vs Diff: Quick Reference
| Command | Use Case | Preserves Commit Info? | Can Apply With |
|---|---|---|---|
| git diff > file.diff | Share uncommitted changes | ❌ | git apply |
| git format-patch > file.patch | Share committed changes | ✅ | git am |
Author: mike-rambil • Updated: 2024-06-10 • Tags: patch, diff, reference