Skip to content

Commit de542e2

Browse files
authored
PATCH: fix annotation-fetch --verbose for signatures (#383)
1 parent 745d3f8 commit de542e2

File tree

1 file changed

+12
-3
lines changed

1 file changed

+12
-3
lines changed

q2cli/builtin/tools.py

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1640,9 +1640,18 @@ def annotation_fetch(input_path, name, verbose):
16401640
click.echo(CONFIG.cfg_style('type', "type")+": ", nl=False)
16411641
click.echo(annotation.annotation_type)
16421642
if verbose:
1643-
click.echo('', nl=True)
1644-
click.echo(CONFIG.cfg_style('type', "contents")+": ", nl=False)
1645-
click.echo(annotation.contents)
1643+
if annotation.annotation_type == 'Signature':
1644+
click.echo('', nl=True)
1645+
click.echo(CONFIG.cfg_style('type', "signer_name")+": ", nl=False)
1646+
click.echo(annotation.signer_name)
1647+
click.echo(CONFIG.cfg_style('type', "signer_email")+": ", nl=False)
1648+
click.echo(annotation.signer_email)
1649+
click.echo(CONFIG.cfg_style('type', "fingerprint")+": ", nl=False)
1650+
click.echo(annotation.fingerprint)
1651+
else:
1652+
click.echo('', nl=True)
1653+
click.echo(CONFIG.cfg_style('type', "contents")+": ", nl=False)
1654+
click.echo(annotation.contents)
16461655

16471656

16481657
@tools.command(

0 commit comments

Comments
 (0)