mirror of
https://github.com/ivuorinen/cheatsheet-tldr.git
synced 2026-02-28 09:53:48 +00:00
Update cheatsheets
This commit is contained in:
@@ -8,10 +8,6 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
> Remove files not tracked by Git from the working tree.
|
||||
> More information: <https://git-scm.com/docs/git-clean>.
|
||||
|
||||
- Delete untracked files:
|
||||
|
||||
`git clean`
|
||||
|
||||
- Interactively delete untracked files:
|
||||
|
||||
`git clean {{[-i|--interactive]}}`
|
||||
@@ -20,14 +16,22 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
`git clean {{[-n|--dry-run]}}`
|
||||
|
||||
- Forcefully delete untracked files:
|
||||
- Immediately force deletion of all untracked files:
|
||||
|
||||
`git clean {{[-f|--force]}}`
|
||||
|
||||
- Forcefully delete untracked [d]irectories:
|
||||
- Delete untracked [d]irectories:
|
||||
|
||||
`git clean {{[-f|--force]}} -d`
|
||||
|
||||
- Delete untracked files, including e[x]cluded files (files ignored in `.gitignore` and `.git/info/exclude`):
|
||||
- Delete only untracked files matching specific paths or glob patterns:
|
||||
|
||||
`git clean -x`
|
||||
`git clean {{[-f|--force]}} -- {{path/to/directory}} '{{*.ext}}'`
|
||||
|
||||
- Delete untracked files except those matching the given patterns:
|
||||
|
||||
`git clean {{[-f|--force]}} {{[-e|--exclude]}} {{'*.ext'}} {{[-e|--exclude]}} {{path/to/directory/}}`
|
||||
|
||||
- Delete untracked files and e[x]cluded files (those listed in `.gitignore` and `.git/info/exclude`):
|
||||
|
||||
`git clean {{[-f|--force]}} -x`
|
||||
|
||||
Reference in New Issue
Block a user