Perforce Command Reference:   [Index] [Prev] [Next]


p4 print

Synopsis

Print the contents of a depot file revision

Syntax

p4 [g-opts] print [ -q ] file[rev] ...

Description

This command writes the contents of a depot file to standard output. A revision specification can be included; if it is not, the head revision is printed.

Any file in the depot can be printed, subject to permission limitations as granted by p4 protect. If the file argument does not map through the client view, you must provide it in depot syntax.

By default, the file is written with a header that describes the location of the file in the depot, the revision number of the printed file, and the number of the changelist that the revision was submitted under. To suppress the header, use the -q flag.

Multiple file patterns can be included; all files matching any of the patterns will be printed.

Options

-q Suppress the one-line file header normally added by Perforce
g_opts See global options section.

Usage Notes

Can File Arg Use
Revision Specifier?
Can File Arg
Use Revision Range?
Minimal
Access Level Required
Yes Yes read

Related Commands

To compare the contents of two depot file revisions p4 diff2
To compare the contents of a revised file in the client worksace to a depot file revision p4 diff



Perforce Command Reference:   [Index] [Prev] [Next]


Copyright 1999 Perforce Software.
Contact us at [email protected]
Last updated: 09/15/99 (Manual version 99.1.cr.6)