I often accidentally create a branch that contains more code than it needs to. When that happens, I delete the branch files, the branch tag, and then start over. The thing that stinks is having to sync the huge pile of data just so I can delete it.
Is there a way to delete server-side?
If p4 sync is used to bring the head revision of this file into another workspace, the file is deleted from that workspace. A file that is open for deletion does not appear on the workspace's have list.
Description. The p4 delete command opens file(s) in a client workspace for deletion from the depot. The files are immediately removed from the client workspace, but are not deleted from the depot until the corresponding changelist is committed with p4 submit .
The p4 clean command takes the following actions when finding inconsistencies between files in a user's workspace and corresponding depot files: Files present in the workspace, but missing from the depot are deleted from the workspace.
On the P4VS dialog, select the default pending changelist or a new changelist. Click Yes. P4VS marks the file for delete and it is placed in a changelist.
Yes, use sync -k.
Add the path you want to delete to your client, e.g.
//depot/oops/... //your-client/oops/...
Then sync that location using the -k option:
p4 sync -k oops/...
This will tell Perforce that your client has the files without actually transferring them. Then you can do:
p4 delete oops/...
p4 submit oops/...
etc.
Use delete -v:
p4 delete -v oops/...
This will delete files without syncing into workspace. It is faster than sync -k and then delete.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With