Create or edit a branch view specification
p4 branch allows you to store a mapping between two sets of files for use with p4 integrate. This command displays a form: enter a view that expresses the mappings between the files you're integrating from (the fromFiles) and the files you're integrating to (the toFiles), specifying both sides of the view in depot syntax.
Once the branch specification has been created and named, you can integrate files by typing p4 integrate -b branchspecname; the branch specification will automatically map all toFiles to their corresponding fromFiles.
Calling p4 branch has no immediate effect on any files in the depot. Perforce will create the branched files in the client workspace the first time you call p4 integrate -b branchspecname.
-d | Delete the named branch specification. Files are not affected by this operation; only the stored mapping from one codeline to another is deleted. Only the user who created the branch can normally use this flag. |
-f | Allows superusers to delete branches they don't own. Also lets superusers change the modification date of the branch specification. |
-i | Read the branch specification from standard input without invoking an editor. |
-o | Write the branch specification to standard output without invoking an editor. |
g_opts | See global options section. |
Can File Arg Use Revision Specifier? |
Can File Arg Use Revision Range? |
Minimal Access Level Required |
---|---|---|
<NA> | <NA> | open |
//depot/project/dev/... //depot/project/r2.0/...
To view a list of existing branch specifications | p4 branches |
To copy changes from one set of files to another | p4 integrate |