For P4D server version prior to To restore a file that was deleted in the depot, p4 sync the last "live" revision of the file, run p4 add to mark it for add, then p4 submit this change.
For example, a If foo. In any of these situations, please do check which files are included in the change you are submitting in either case; it is possible it may contain other files not yet ready for submit - especially if you are working with the default pending changelist.
For P4V version Right-click on this file and select 'Undo Changes If 'Submit' button was not clicked in c above, review and then submit the save changelist to undo the delete action. To undo a submitted changelist that had deleted multiple files as discussed in 1b above, select the submitted changelist number in the "Submitted" tab, right click and select "Undo Changes in Changelist '' For P4V prior to version Then, you would:.
To bring an entire depot path back to an earlier time, again start by opening the Submitted Changelists. Right-click on the file and choose 'submit'. You may see the warning message, " Deleted: Edits to the file cannot be submitted without re-adding the file ".
This means that you have the file opened-for-edit, but someone has deleted this file before you have submitted your changes. To submit your file:. Undoing the ' p4 obliterate ' of a file or file revision is a non-trivial task, requiring access to archive files, journals and backups at least. Contact your Perforce administrator for assistance.
Replace 'username' with the user who submitted the change, and add an appropriate timestamp. Running 'p4 filelog' for a given file will allow you to see which file revision s have been deleted. In P4V, look for changelists containing the deleted files in the 'Submitted Changelists' pane filtering by your username, or use the 'History' tab for a given depot path to see all changes affecting those files.
As a user with super privileges, impersonate the user that owns the client workspace and use p4 revert -k to revert files. The p4 login user command generates a login ticket for the user allowing you to run p4 revert with the credentials of the workspace owner without requiring a password. Use the global options to p4 to set the user -u , client workspace -c , and host -H fields and use the -k flag with p4 revert which marks the file as reverted in server metadata without altering files in the workspace.
Use p4 client -o workspace to get the hostname to use with the -H host option to p4 revert -k , for example:. If files are opened in a workspace that's no longer needed, delete the client workspace:. Deleting a client workspace does not remove files from the client workspace. To clean up the deleted workspace file system, you must delete the files on the machine containing the workspace.
Workspaces containing shelved files require special consideration as deletion is prevented:. With Helix Server Alternatively, you can use p4 shelve -df to delete each shelved change and then delete the workspace:. If the message from p4 client -df does not contain shelved changes numbers, use p4 changes -s shelved -u user -c workspace to find shelved changes for a specific u ser workspace.
To delete a client workspace or a shelved change using p4 client -df or p4 shelve -df , you must be a user with admin or super privileges. Sometimes impersonating the perforce user and client to do a revert can require a Helix Server super user to reset their password. The superuser can simply change the user's password, login as the user, and then revert the files. For example, to reset the password:. In cases where the client workspace is locked, the Helix Server admin can use the -f flag option with the p4 client command to modify another user's workspace.
For example:. To revert a file, click the ellipsis To revert all changed files in a folder, click the ellipsis Your search for returned result s. Account Settings Logout. All Files.
0コメント