Issue 2084 wish: darcs show patch

Title wish: darcs show patch
Priority wishlist Status unknown
Milestone Resolved in
Superseder Nosy List owst
Assigned To

Created on 2011-07-05.10:17:13 by owst, last changed 2012-12-13.14:34:42 by owst.

msg14569 (view) Author: owst Date: 2011-07-05.10:17:12
Given a patch hash, this command should output details of the patch,
formatted according to a format string or similar.

My original need for this was as a post-processor of annotate
--machine-readable, which gives output in the form:
source_patch_hash line

with which, I wanted to do something like:

$ darcs annotate --machine foo.hs | while read hash; do darcs show patch
-f '%e' $hash; done | sort | uniq -c

to extract an ordered list of authors, on a given file.
msg16406 (view) Author: markstos Date: 2012-12-13.14:25:13
owst, could you post a more detailed "screenshot" mockup of what the tool 
would look like in action?
msg16408 (view) Author: owst Date: 2012-12-13.14:34:41
Something like this:

    > darcs show patch --format '%an %d %n' $hash
    Owen Stephens<TAB>01/01/2012 00:00:00+00:00<TAB>This is my patch name

expected format specifiers:
    %a - author
    %an - author name
    %ae - author email
    %d - date
    %n - name
    %l - log
    %s - summary
    %c - changes

I suppose we should try and be consistent with what other VCSs provide
in their
format specifiers.

<TAB> could reasonably be \0 also.

I think that's what I would like it to look like.
Date User Action Args
2011-07-05 10:17:13owstcreate
2012-12-13 14:25:15markstossetmessages: + msg16406
2012-12-13 14:34:42owstsetmessages: + msg16408