notes/devops/vcs/git/git-clean.txt
Ihar Hancharenka b9c36c1e5a m
2024-02-04 19:40:05 +03:00

24 строки
511 B
Plaintext

git clean [optional path]
delete untracked and ignored files
-h
help for the clean commands
-n, --dry-run
for safe preview
-d
for delete directories
-f, --force
to force deletion
-x
delete files even if they are in .gitignore
-X
remove ignored files only
-e, --exclude <pattern>
exclude pattern
-ndx
combine options
tip:
remove the end slash at .gitignore ad end the dirs with /-only (instead of /*)