The title pretty much says it all.

Show me all submissions...
To a depot path (e.g. //Proj/top/subtop/...)
By a specific user (sclause)
With description containing a specific word ("reindeer")

p4 cli or p4v

1

There are 1 best solutions below

0
Samwise On

The first two requirements can be passed as arguments to the p4 changes command:

p4 changes -u sclause //Proj/top/subtop/...

Since descriptions aren't indexed you'll need to do your own post-processing for that part. Using grep is a little tricky since change descriptions can span multiple lines and you'd have to string together multiple statements to capture the word match and then associate it with the change number; I'd probably use Python and do something like:

from P4 import P4

with P4().connect() as p4:
    for change in p4.run_changes("-u", "sclause", "//Proj/top/subtop/..."):
        if "reindeer" in change['desc']:
            print(change['change'])