| 1 |
.TH HG PURGE "" "" "" |
| 2 |
.SH NAME |
| 3 |
hg purge \- removes files not tracked by Mercurial |
| 4 |
.\" Man page generated from reStructuredText. |
| 5 |
. |
| 6 |
.SH SYNOPSIS |
| 7 |
.sp |
| 8 |
.nf |
| 9 |
.ft C |
| 10 |
hg purge [OPTION]... [DIR]... |
| 11 |
.ft P |
| 12 |
.fi |
| 13 |
.SH DESCRIPTION |
| 14 |
.sp |
| 15 |
Delete files not known to Mercurial. This is useful to test local |
| 16 |
and uncommitted changes in an otherwise\-clean source tree. |
| 17 |
.sp |
| 18 |
This means that purge will delete the following by default: |
| 19 |
.INDENT 0.0 |
| 20 |
.IP \(bu 2 |
| 21 |
. |
| 22 |
Unknown files: files marked with "?" by \%\fBhg status\fP\: |
| 23 |
.IP \(bu 2 |
| 24 |
. |
| 25 |
Empty directories: in fact Mercurial ignores directories unless |
| 26 |
they contain files under source control management |
| 27 |
.UNINDENT |
| 28 |
.sp |
| 29 |
But it will leave untouched: |
| 30 |
.INDENT 0.0 |
| 31 |
.IP \(bu 2 |
| 32 |
. |
| 33 |
Modified and unmodified tracked files |
| 34 |
.IP \(bu 2 |
| 35 |
. |
| 36 |
Ignored files (unless \-i or \-\-all is specified) |
| 37 |
.IP \(bu 2 |
| 38 |
. |
| 39 |
New files added to the repository (with \%\fBhg add\fP\:) |
| 40 |
.UNINDENT |
| 41 |
.sp |
| 42 |
The \-\-files and \-\-dirs options can be used to direct purge to delete |
| 43 |
only files, only directories, or both. If neither option is given, |
| 44 |
both will be deleted. |
| 45 |
.sp |
| 46 |
If directories are given on the command line, only files in these |
| 47 |
directories are considered. |
| 48 |
.sp |
| 49 |
Be careful with purge, as you could irreversibly delete some files |
| 50 |
you forgot to add to the repository. If you only want to print the |
| 51 |
list of files that this program would delete, use the \-\-print |
| 52 |
option. |
| 53 |
.SH OPTIONS |
| 54 |
.INDENT 0.0 |
| 55 |
.TP |
| 56 |
.B \-a, \-\-abort\-on\-err |
| 57 |
. |
| 58 |
abort if an error occurs |
| 59 |
.TP |
| 60 |
.B \-\-all |
| 61 |
. |
| 62 |
purge ignored files too |
| 63 |
.TP |
| 64 |
.B \-i, \-\-ignored |
| 65 |
. |
| 66 |
purge only ignored files |
| 67 |
.TP |
| 68 |
.B \-\-dirs |
| 69 |
. |
| 70 |
purge empty directories |
| 71 |
.TP |
| 72 |
.B \-\-files |
| 73 |
. |
| 74 |
purge files |
| 75 |
.TP |
| 76 |
.B \-p, \-\-print |
| 77 |
. |
| 78 |
print filenames instead of deleting them |
| 79 |
.TP |
| 80 |
.B \-0, \-\-print0 |
| 81 |
. |
| 82 |
end filenames with NUL, for use with xargs (implies \-p/\-\-print) |
| 83 |
.TP |
| 84 |
.B \-\-confirm |
| 85 |
. |
| 86 |
ask before permanently deleting files |
| 87 |
.TP |
| 88 |
.BI \-I, \-\-include \ <PATTERN[+]> |
| 89 |
. |
| 90 |
include names matching the given patterns |
| 91 |
.TP |
| 92 |
.BI \-X, \-\-exclude \ <PATTERN[+]> |
| 93 |
. |
| 94 |
exclude names matching the given patterns |
| 95 |
.UNINDENT |
| 96 |
.sp |
| 97 |
[+] marked option can be specified multiple times |
| 98 |
.SH ALIASES |
| 99 |
.sp |
| 100 |
.nf |
| 101 |
.ft C |
| 102 |
clean |
| 103 |
.ft P |
| 104 |
.fi |
| 105 |
.\" Generated by docutils manpage writer. |
| 106 |
.\" |
| 107 |
. |