commit 06182df71f8290bc68235fc783d1a6420d9c2040
parent a5761fe8a87b4999efda9be458250d8a439f0df7
Author: ThomasV <thomasv@gitorious>
Date: Wed, 16 May 2012 19:33:42 +0200
rm mnemonic option, paste seed as both hexadecimal and mnemonic
Diffstat:
2 files changed, 3 insertions(+), 7 deletions(-)
diff --git a/electrum b/electrum
@@ -48,7 +48,6 @@ if __name__ == '__main__':
parser.add_option("-g", "--gui", dest="gui", default="qt", help="gui")
parser.add_option("-w", "--wallet", dest="wallet_path", help="wallet path (default: electrum.dat)")
parser.add_option("-o", "--offline", action="store_true", dest="offline", default=False, help="remain offline")
- parser.add_option("-m", "--mnemonic", action="store_true", dest="show_mnemonic", default=False, help="[seed] print the seed as mnemonic")
parser.add_option("-a", "--all", action="store_true", dest="show_all", default=False, help="show all addresses")
parser.add_option("-b", "--balance", action="store_true", dest="show_balance", default=False, help="show the balance at listed addresses")
parser.add_option("-k", "--keys",action="store_true", dest="show_keys",default=False, help="show the private keys of listed addresses")
@@ -266,10 +265,7 @@ if __name__ == '__main__':
elif cmd == 'seed':
from electrum import mnemonic
seed = wallet.pw_decode( wallet.seed, password)
- if options.show_mnemonic:
- print ' '.join(mnemonic.mn_encode(seed))
- else:
- print seed
+ print seed + ' "' + ' '.join(mnemonic.mn_encode(seed)) + '"'
elif cmd == 'deseed':
if not wallet.seed:
@@ -291,7 +287,7 @@ if __name__ == '__main__':
elif cmd == 'reseed':
if wallet.seed:
- print "This wallet already has a seed"
+ print "This wallet already has a seed", wallet.seed
else:
ns = options.wallet_path+'.seed'
try:
diff --git a/lib/gui_qt.py b/lib/gui_qt.py
@@ -769,7 +769,7 @@ class ElectrumWindow(QMainWindow):
app = QApplication
b = QPushButton("Copy to Clipboard")
- b.clicked.connect(lambda: app.clipboard().setText(' '.join(mnemonic.mn_encode(seed))))
+ b.clicked.connect(lambda: app.clipboard().setText(seed + ' "' + ' '.join(mnemonic.mn_encode(seed))+'"'))
hbox.addWidget(b)
b = QPushButton("View as QR Code")
b.clicked.connect(lambda: ElectrumWindow.show_seed_qrcode(seed))