From 9fcb84a8d2b06df500963be0425cc800bc876bbc Mon Sep 17 00:00:00 2001 From: Satoshi Nakamoto <65907137+SatoshiNakamotoBitcoin@users.noreply.github.com> Date: Sun, 1 Jan 2023 19:11:05 +0100 Subject: [PATCH] Update spvblock.py --- pybitblock/SPV/spvblock.py | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/pybitblock/SPV/spvblock.py b/pybitblock/SPV/spvblock.py index 80f0c59..f9e0926 100644 --- a/pybitblock/SPV/spvblock.py +++ b/pybitblock/SPV/spvblock.py @@ -34,6 +34,7 @@ from pycoingecko import CoinGeckoAPI from binascii import unhexlify from embit import bip39 from embit.wordlists.bip39 import WORDLIST +from io import StringIO version = "2.0.14" @@ -3767,6 +3768,26 @@ def callGitNostrSeedTerminal(): except: menuSelection() +def callGitNostrQRSeedTerminal(): + try: + clear() + blogo() + output = render( + "QR", colors=['yellow'], align='left', font='tiny' + ) + if os.path.isdir ('nostr_QRseed'): + print("...pass...") + else: # Check if the file 'bclock.conf' is in the same folder + os.system("mkdir nostr_QRseed && cd nostr_QRseed && wget https://gist.githubusercontent.com/odudex/9e848a91d23e967309bd1719910021e6/raw/dbe04893f4ee2e0aa020735528f7f19bb2d13a7e/nostr_c_seed_qr.py") + clear() + blogo() + print(output) + responseC = input("Hex to BIP39 QR & BIP39 to Hex QR: ") + os.system(f"cd nostr_QRseed && python3 nostr_c_seed_qr.py {responseC}") + input("\a\nContinue...") + except: + menuSelection() + #---------------------------------Cashu---------------------------------- def callGitCashu(): if not os.path.isdir('Cashu'): @@ -5174,6 +5195,7 @@ def nostrConn(): \033[1;32;40mD.\033[0;37;40m Mac arm64 (SOON) \033[1;32;40mE.\033[0;37;40m Windows \033[1;32;40mS.\033[0;37;40m Bip39 + \033[1;32;40mW.\033[0;37;40m QR \u001b[31;1mR.\033[0;37;40m Return \n\n\x1b[?25h""".format(n,b, version, checkupdate())) nostrmenu(input("\033[1;32;40mSelect option: \033[0;37;40m")) @@ -7784,6 +7806,8 @@ def nostrmenu(menunos): callGitNostrWinTerminal() elif menunos in ["S", "s"]: callGitNostrSeedTerminal() + elif menunos in ["W", "w"]: + callGitNostrQRSeedTerminal() def testClockRemote(): b = rpc('getblockcount')