Perforce 99.2 Command Reference (99.2.cr.3)
<< Previous Chapter
Views
Table of Contents
Index
Perforce on the Web
Next Chapter >>
Index

File Types


Synopsis

Perforce supports four base file types: text files, compressed binary files, Macintosh resource forks, and symbolic links. File type modifiers are then applied to the base types allowing for support of RCS keyword expansion, file compression, and more.

Perforce attempts to determine the type of the file automatically: when a file is opened with p4 add, Perforce first decides if the file is a regular file or a symbolic link, and then examines the first part of the file to determine whether it is text or binary. If any non-text characters are found, the file is assumed to be binary; otherwise, the file is assumed to be text.

The base Perforce file types are:



Keyword



Description



Comments

Server
Storage Type

text

Text file

Treated as text on the client. Line-ending translations are performed automatically on Windows and Macintosh clients.

delta

binary

Non-text file

Accessed as binary files on the client. Stored compressed within the depot.

full file,
compressed

symlink

Symbolic link

UNIX clients (and the BeOS client) access these as symbolic links. Non-UNIX clients treat them as (small) text files.

delta

apple

Multi-forked Macintosh file

AppleSingle storage of Mac data fork, resource fork, file type and file creator. New to Perforce 99.2.

For full details, please see the Mac client release notes at http://www.perforce.com/perforce/technical.html

full file,
compressed, AppleSingle format.

resource

Macintosh resource fork

The only file type for Mac resource forks in Perforce 99.1 and before. Still supported, but we recommend using the new apple file type instead.

For full details, please see the Mac client release notes at http://www.perforce.com/perforce/technical.html

full file,
compressed

The file type modifiers are:

Modifier
Description
Comments

+x

Execute bit set on client

Used for executable files.

+w

File is always writable on client

+k

RCS keyword expansion

Expands the RCS keywords $Id$ and $Header$ to
$Id: //depot/file#revision $ and
$Header: //depot/file#revision $.

+C

Server stores the full compressed version of each file revision

Default server storage mechanism for binary files.

+D

Server stores deltas in RCS format

Default server storage mechanism for text files.

+F

Server stores full file per revision

Useful for long ASCII files that aren't read by users as text, such as PostScript files.

+S

Only the head revision is stored on the server

Older revisions are overwritten within the depot. Useful for executable or .obj files.

A file's type is normally preserved between revisions, but can be overridden or changed with the -t flag during add, edit, or reopen operations:

The filetype argument is specified as basetype+modifiers. For example, to change file foo's type to executable text with RCS keyword expansion, use p4 edit -t text+kx foo.

Usage Notes


Perforce 99.2 Command Reference (99.2.cr.3)
<< Previous Chapter
Views
Table of Contents
Index
Perforce on the Web
Next Chapter >>
Index
Please send comments and questions about this manual to [email protected].
Copyright 1997, 2000 Perforce Software. All rights reserved.
Last updated: 02/16/00