def list_fpgas(self):
"""Return a list with all the supported FPGAs"""
# Print table
click.echo('\nSupported FPGAs:\n')
FPGALIST_TPL = ('{fpga:30} {type:<5} {size:<5} {pack:<10}')
terminal_width, _ = click.get_terminal_size()
click.echo('-' * terminal_width)
click.echo(FPGALIST_TPL.format(
fpga=click.style('FPGA', fg='cyan'), type='Type',
size='Size', pack='Pack'))
click.echo('-' * terminal_width)
for fpga in self.fpgas:
click.echo(FPGALIST_TPL.format(
fpga=click.style(fpga, fg='cyan'),
type=self.fpgas[fpga]['type'],
size=self.fpgas[fpga]['size'],
pack=self.fpgas[fpga]['pack']))
评论列表
文章目录