Jump to content


Revert another user’s open files


  • Please log in to reply
3 replies to this topic

#1 David Yerkess

David Yerkess

    Advanced Member

  • Members
  • PipPipPip
  • 78 posts

Posted 23 July 2018 - 04:52 PM

We have updated Perforce Server to 2018.1 and client P4V to 2018.2.

I have found that the revert command is behaving different.

Before as admin I could use
p4 revert -C bruno_ws //depot/www/dev/Jam.html

Now I have to add the global option -H
p4 -H Bruno revert -C bruno_ws //depot/www/dev/Jam.html

Also if the workspace is locked, then I cannot revert a user's file without removing the lock from his client spec (or knowing his password).


Is this an intended change?


Thanks,

David.

#2 Sambwise

Sambwise

    Advanced Member

  • Members
  • PipPipPip
  • 611 posts

Posted 23 July 2018 - 06:48 PM

That sounds like it completely defeats the purpose of "revert -C".  As a superuser you've always been able to do:

p4 login OTHERUSER
p4 -u OTHERUSER -c OTHERCLIENT -H OTHERHOST revert -k //depot/whatever

but the point of "revert -C" was to bundle all that up into one command that doesn't require you to spoof four different things.

#3 dave.foglesong

dave.foglesong

    Newbie

  • Members
  • Pip
  • 7 posts

Posted 23 July 2018 - 07:02 PM

Are you running the latest build of p4d? The release notes show a fix in patch 2 for a bug that sounds like what you're describing:

Bugs fixed in 2018.1 Patch 2
...
#1665779 (Bugs #92403, #95219) **
    'p4 revert -C client' would fail to revert files in the target
    workspace if that workspace was locked or specified a host other
    than the one the command was run from. This has been fixed.

#4 David Yerkess

David Yerkess

    Advanced Member

  • Members
  • PipPipPip
  • 78 posts

Posted 24 July 2018 - 01:39 PM

View Postdave.foglesong, on 23 July 2018 - 07:02 PM, said:

Are you running the latest build of p4d? The release notes show a fix in patch 2 for a bug that sounds like what you're describing:

Bugs fixed in 2018.1 Patch 2
...
#1665779 (Bugs #92403, #95219) **
'p4 revert -C client' would fail to revert files in the target
workspace if that workspace was locked or specified a host other
than the one the command was run from. This has been fixed.

Thanks Dave, I didn't think about checking if a patch had been released. We are indeed on patch 1.
It took us two years to decide to update the server and I don't think I can get it updated again just for this fix. :(




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users