Change the location and/or layout of your workspace
To change the location of files in your workspace, issue the p4
client
command and change either or both of the
Root:
and View
fields. Before changing these
settings, ensure that you have no files checked out (by submitting or
reverting open files).
If you’re using streams, you must change the Paths
field
in the stream spec, rather than the View
field, in the
client spec.
If you intend to modify both fields, perform the following steps to ensure that your workspace files are located correctly:
- To remove the files from their old location in the workspace, issue
the
p4 sync …#none
command. - Change the
Root
field. (The new client workspace root directory must exist on your computer before you can retrieve files into it.) - To copy the files to their new locations in the workspace, perform a
p4 sync
. (If you forget to perform thep4 sync …#none
before you change the workspace view, you can always remove the files from their client workspace locations manually). - Users of streams, change the
Paths
field in the stream spec. Users of classic Helix Core Server branches, change theView
field in the client spec. - Again, perform a
p4 sync
. This time, syncing changes the layout of the workspace. The files in the client workspace are synced to their new locations.