When using the following p4 command for a shelved file, the diff is also appended at the end of the output.
> p4 describe -S 1529307
Change 1529307 by who@client on 2015/09/10 14:03:56 *pending*
Comment
Shelved files ...
... //depot/projects/afile.py#4 edit
Differences ...
==== //depot/projects/afile.py#4 (text) ====
1c1
< testing1-2-3-4-5-6-7
---
> testing1-2-3-4-5-6-7-8-9-10
However when doing the similar in P4Python, the data returned from the run('describe -S') function does not contain the diff of the versions.
{
'status': 'pending',
'code': 'stat',
'depotFile0': '//depot/projects/afile.py',
'changeType': 'public',
'action0': 'edit',
'fileSize0': '28',
'shelved': '',
'client': 'client',
'user': 'who',
'time': '144036',
'rev0': '4',
'digest0': '8C425B5CF',
'data': '',
'type0': 'text',
'change': '1529307',
'desc': 'Comment\n'
}
The only workaround I could think of is to use the depot-path from here to find the file, and then diff it with its previous version in the depot. However I still think that there should be an easier way that this information is embedded in P4Python.
Thanks!