<table><tr><td style="">krake added a comment.
</td><a style="text-decoration: none; padding: 4px 8px; margin: 0 8px 8px; float: right; color: #464C5C; font-weight: bold; border-radius: 3px; background-color: #F7F7F9; background-image: linear-gradient(to bottom,#fff,#f1f0f1); display: inline-block; border: 1px solid rgba(71,87,120,.2);" href="https://phabricator.kde.org/D22352">View Revision</a></tr></table><br /><div><div><p>I am very much in favor of adding this but I am thinking we probably want this a bit more generic.<br />
For a console tool the commandline switches are very much like API, so having an email specific switch doesn't "feel" right.</p>

<p>For kabcclient, which is kind of the precursor of this, we supported various input/output formats and format specific options through generic commandline switches:<br />
<a href="http://manpages.ubuntu.com/manpages/trusty/en/man1/kabcclient.1.html" class="remarkup-link" target="_blank" rel="noreferrer">http://manpages.ubuntu.com/manpages/trusty/en/man1/kabcclient.1.html</a><br />
<a href="https://phabricator.kde.org/source/kdepim/browse/master/console/kabcclient/src/formatfactory.cpp;ee3dfc152d1d71df22b60bdcdee317fb9997ab97" class="remarkup-link" target="_blank" rel="noreferrer">https://phabricator.kde.org/source/kdepim/browse/master/console/kabcclient/src/formatfactory.cpp;ee3dfc152d1d71df22b60bdcdee317fb9997ab97</a></p>

<p>We also had a tool for calendar called konsolekalendar which also had different types of output<br />
<a href="https://phabricator.kde.org/source/kdepim/browse/master/console/konsolekalendar/konsolekalendarexports.cpp;ee3dfc152d1d71df22b60bdcdee317fb9997ab97" class="remarkup-link" target="_blank" rel="noreferrer">https://phabricator.kde.org/source/kdepim/browse/master/console/konsolekalendar/konsolekalendarexports.cpp;ee3dfc152d1d71df22b60bdcdee317fb9997ab97</a></p>

<p>"raw" would work across all payload types, maybe even something like "human".</p>

<p>Main difficulty I see is that the "show" command supports a list of items and they don't necessarily need to have the same payload type.<br />
So I am a bit torn between "output-format" and something like "email-format", "contact-format" and so on</p></div></div><br /><div><strong>REPOSITORY</strong><div><div>R723 Akonadi CLI Client</div></div></div><br /><div><strong>REVISION DETAIL</strong><div><a href="https://phabricator.kde.org/D22352">https://phabricator.kde.org/D22352</a></div></div><br /><div><strong>To: </strong>dfaure, marten, krake<br /><strong>Cc: </strong>kde-pim<br /></div>