Add git add -p
tip
parent
8861d56463
commit
870d11cf26
1 changed files with 2 additions and 0 deletions
|
@ -37,6 +37,8 @@ More information is available in the [Contributing guidelines][contributing].
|
|||
- changes can be reverted (`git restore <file(s)>`)
|
||||
1. Stage the file(s) (`git add <file(s)>`)
|
||||
- staged files can be un-staged (`git restore --staged <file(s)>`)
|
||||
- if you have multiple changes in a file, but only want to stage some of them in this commit,
|
||||
use `git add -p` to mark which chunks you want to stage.
|
||||
1. Commit the staged files (`git commit -m "<message>"`)
|
||||
- leave off the second double-quotes to write a multi-line commit message
|
||||
- be careful using certain punctuation when doing this (e.g. backticks)
|
||||
|
|
Reference in a new issue