[p4] Find source changelist for a target changelist

Sambwise perforce-user-forum at forums.perforce.com
Fri Mar 31 00:40:01 PDT 2017


Posted on behalf of forum user 'Sambwise'.



[http://forums.perforce.com/index.php?app=forums&module=forums&section=findpost&pid=21534]
tanvirkazmi, on 2017/03/29 09:29:25 UTC, said:
>    1. Do a "p4 describe -s" of the destination changelist to identify all impacted files,
>   2. Do a "p4 filelog" on each entry found in previous describe to locate the latest contributing branch file version (from source branch)
>   3. Finally, do a "p4 changes" on each file to get the source changelist number from the source stream
>     
I think you can pare the runtime down a good bit by starting with "p4
filelog @=CHANGE".  It might also be a little faster to do
"files -a" on the ranges to get the change numbers rather than
"p4 changes" (unless you need the other info that's in the changes
output but not the files output).



--
Please click here to see the post in its original format:
  http://forums.perforce.com/index.php?/topic/5262-find-source-changelist-for-a-target-changelist


More information about the perforce-user mailing list