add the old snippet md files

This commit is contained in:
Travis Shears 2025-06-05 16:20:57 +02:00
parent fc0dd204c7
commit bcf8313a4b
110 changed files with 3048 additions and 0 deletions

View file

@ -0,0 +1,18 @@
---
title: "better git add"
date: 2020-01-11T05:07:50+01:00
draft: false
snippet_types: ["git"]
---
```shell
$ git add -p
```
I tend to use magit in emacs to stange and unstage files/hunks but in a pinch **-p** or **git add -i** +
selecting patch works great. You can choose exactly which hunks you want to stage leading to cleaner
incrimental commits. The bonus to using magit is you can easily edit the file during the process.
source:
[git docs](https://git-scm.com/docs/git-add)