2016-10-20 07:40:46 -07:00
|
|
|
#!/usr/bin/env python3
|
|
|
|
import json
|
|
|
|
from collections import OrderedDict
|
|
|
|
|
2016-10-20 08:07:56 -07:00
|
|
|
coins = json.load(open('../../trezor-common/coins.json', 'r'))
|
2016-10-20 07:40:46 -07:00
|
|
|
|
|
|
|
print('_coins = [')
|
|
|
|
for c in coins:
|
|
|
|
d = OrderedDict()
|
2016-11-09 05:46:59 -08:00
|
|
|
for n in ['coin_name', 'coin_shortcut', 'address_type', 'maxfee_kb', 'address_type_p2sh', 'address_type_p2wpkh', 'address_type_p2wsh', 'signed_message_header']:
|
2016-10-20 07:40:46 -07:00
|
|
|
d[n] = c[n]
|
2016-11-09 05:46:59 -08:00
|
|
|
print(' CoinType(')
|
2016-10-20 07:40:46 -07:00
|
|
|
for k in d:
|
2016-11-09 05:46:59 -08:00
|
|
|
print(' %s=%s,' % (k, repr(d[k])))
|
|
|
|
print(' ),')
|
2016-10-20 07:40:46 -07:00
|
|
|
print(']\n')
|