.\" ** You probably do not want to edit this file directly ** .\" It was generated using the DocBook XSL Stylesheets (version 1.69.1). .\" Instead of manually editing it, you probably should edit the DocBook XML .\" source for it and then use the DocBook XSL Stylesheets to regenerate it. .TH "GIT\-CLEAN" "1" "09/19/2007" "Git 1.5.3.2" "Git Manual" .\" disable hyphenation .nh .\" disable justification (adjust text to left margin only) .ad l .SH "NAME" git\-clean \- Remove untracked files from the working tree .SH "SYNOPSIS" .sp .nf \fIgit\-clean\fR [\-d] [\-f] [\-n] [\-q] [\-x | \-X] [\-\-] \&... .fi .SH "DESCRIPTION" Removes files unknown to git. This allows to clean the working tree from files that are not under version control. If the \fI\-x\fR option is specified, ignored files are also removed, allowing to remove all build products. When optional \&... arguments are given, the paths affected are further limited to those that match them. .SH "OPTIONS" .TP \-d Remove untracked directories in addition to untracked files. .TP \-f If the git configuration specifies clean.requireForce as true, git\-clean will refuse to run unless given \-f or \-n. .TP \-n Don't actually remove anything, just show what would be done. .TP \-q Be quiet, only report errors, but not the files that are successfully removed. .TP \-x Don't use the ignore rules. This allows removing all untracked files, including build products. This can be used (possibly in conjunction with \fBgit\-reset\fR(1)) to create a pristine working directory to test a clean build. .TP \-X Remove only files ignored by git. This may be useful to rebuild everything from scratch, but keep manually created files. .SH "AUTHOR" Written by Pavel Roskin .SH "GIT" Part of the \fBgit\fR(7) suite