.TH HG CAT "" "" "" .SH NAME hg cat \- output the current or given revision of files .\" Man page generated from reStructuredText. . .SH SYNOPSIS .sp .nf .ft C hg cat [OPTION]... FILE... .ft P .fi .SH DESCRIPTION .sp Print the specified files as they were at the given revision. If no revision is given, the parent of the working directory is used. .sp Output may be to a file, in which case the name of the file is given using a template string. See \%\fBhg help templates\fP\:. In addition to the common template keywords, the following formatting rules are supported: .INDENT 0.0 .TP .B \fB%%\fP .sp literal "%" character .TP .B \fB%s\fP .sp basename of file being printed .TP .B \fB%d\fP .sp dirname of file being printed, or \(aq.\(aq if in repository root .TP .B \fB%p\fP .sp root\-relative path name of file being printed .TP .B \fB%H\fP .sp changeset hash (40 hexadecimal digits) .TP .B \fB%R\fP .sp changeset revision number .TP .B \fB%h\fP .sp short\-form changeset hash (12 hexadecimal digits) .TP .B \fB%r\fP .sp zero\-padded changeset revision number .TP .B \fB%b\fP .sp basename of the exporting repository .TP .B \fB\e\fP .sp literal "" character .UNINDENT .sp Template: .sp The following keywords are supported in addition to the common template keywords and functions. See also \%\fBhg help templates\fP\:. .INDENT 0.0 .TP .B data . String. File content. .TP .B path . String. Repository\-absolute path of the file. .UNINDENT .sp Returns 0 on success. .SH OPTIONS .INDENT 0.0 .TP .BI \-o, \-\-output \ . print output to file with formatted name .TP .BI \-r, \-\-rev \ . print the given revision .TP .B \-\-decode . apply any matching decode filter .TP .BI \-I, \-\-include \ . include names matching the given patterns .TP .BI \-X, \-\-exclude \ . exclude names matching the given patterns .TP .BI \-T, \-\-template \