mirror of
https://github.com/tldr-pages/tldr.git
synced 2024-12-26 18:32:41 +03:00
4bfdfacfa7
See: (`git add -A` vs `git add .`)[http://stackoverflow.com/questions/26042390/git-add-asterisk-vs-git-add-period]
24 lines
317 B
Markdown
24 lines
317 B
Markdown
# git add
|
|
|
|
> Adds changed files to the index.
|
|
|
|
- Add a file to the index:
|
|
|
|
`git add {{path/to/file}}`
|
|
|
|
- Add all files (tracked and untracked):
|
|
|
|
`git add -A`
|
|
|
|
- Only add already tracked files:
|
|
|
|
`git add -u`
|
|
|
|
- Also add ignored files:
|
|
|
|
`git add -f`
|
|
|
|
- Add parts of a file interactively:
|
|
|
|
`git add -p {{path/to/file}}`
|