Naming conventions

Perforce enforces only a few rules related to what you name Perforce objects:

Otherwise, naming conventions are limited to best practices; the guiding principles being to use names that help you guess what the content is, to use consistent naming schemes, and to choose names that are likely to group like objects in alphabetical listings.

The following table provides some suggestions that are specific to Perforce objects:

Object Naming convention

branches

Best to name them.

clients

The following scheme is commonly used, but not enforced in any way. Use it if it suits your purpose.

user.machineTag.product

user.machineTag.product.branch

user is the OS user; machineTag is the host name or something that describes the host; for example Win7VM or P4MBPro (for Perforce MacBook Pro).

Whether you use product or product.branch depends on whether your workspace gets re-purposed from stream to stream (in which case just use product), or you have multiple workspaces, one for each branch (in which case use product.branch, effectively tying the workspace name to the branch).

depots

Best to keep the names short.

Depot names are part of an organization hierarchy for all your digital assets, so naming them and planning directory structure is especially important.

jobs

Name jobs to match your external defect tracker issues: for example, PRJ-1234 for JIRA issues.

labels

Label names are site-dependent and might vary with code management schemes and versioning needs. For example R-3.2.0 might refer to release 3.2.0.