You can use static labels to archive the state of your client workspace
(meaning the currently synced file revisions) by issuing the
labelsync command. The label you specify must have the
same view as your client workspace.
For example, to record the configuration of your current client
workspace using the existing
ws_config label, use the
$ p4 labelsync -l ws_config
All file revisions that are synced to your current workspace and visible
through both the workspace view and the label view (if any) are tagged
ws_config label. Files that were previously tagged
ws_config, then subsequently removed from your
p4 sync #none), are untagged.
To sync the files tagged by the
ws_config label (thereby
recreating the workspace configuration):
$ p4 sync @ws_config
You can control how static labels are stored using the
- autoreload stores the labels in the unload depot. This storage option can improve performance on sites that make heavy use of labels.
- noautoreload stores the labels in the
These storage options do not affect automatic labels.
p4 tag allows you to specify any revision of any file, and add that revision to an existing label or create a new label if the label does not exist.
p4 labelsync allows you to use the named label to tag the current contents of the client.
When syncing static labels, the performance is the same regardless of how they are created.