1
0
mirror of https://github.com/trezor/trezor-firmware.git synced 2024-12-22 22:38:08 +00:00

trezorctl: add no-backup option to reset-device

This commit is contained in:
Pavol Rusnak 2018-10-08 14:17:07 +02:00
parent d49a38d80f
commit c395501d2d
No known key found for this signature in database
GPG Key ID: 91F3B339B9A02A3D
2 changed files with 5 additions and 0 deletions

View File

@ -440,6 +440,7 @@ def recovery_device(
@click.option("-l", "--label")
@click.option("-u", "--u2f-counter", default=0)
@click.option("-s", "--skip-backup", is_flag=True)
@click.option("-n", "--no-backup", is_flag=True)
@click.pass_obj
def reset_device(
connect,
@ -450,6 +451,7 @@ def reset_device(
label,
u2f_counter,
skip_backup,
no_backup,
):
return device.reset(
connect(),
@ -461,6 +463,7 @@ def reset_device(
"english",
u2f_counter,
skip_backup,
no_backup,
)

View File

@ -154,6 +154,7 @@ def reset(
language,
u2f_counter=0,
skip_backup=False,
no_backup=False,
):
if client.features.initialized:
raise RuntimeError(
@ -170,6 +171,7 @@ def reset(
label=label,
u2f_counter=u2f_counter,
skip_backup=bool(skip_backup),
no_backup=bool(no_backup),
)
resp = client.call(msg)