From fbeaec2a854e9bfa9dfa816ef16332d4c7dc1e7b Mon Sep 17 00:00:00 2001 From: Marco Raber Date: Mon, 24 Aug 2020 16:52:54 +0200 Subject: [PATCH] removed print statements --- pythonTOTP-dmenu | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/pythonTOTP-dmenu b/pythonTOTP-dmenu index f6bdeb4..5552cd0 100755 --- a/pythonTOTP-dmenu +++ b/pythonTOTP-dmenu @@ -8,20 +8,16 @@ keys=[] names=[] alllines=keysfile.readlines() for i in range(0, len(alllines)): - if i%2==0: - # thisname=alllines[i] - # thisname=thisname[:-2] + if i%2==0: #alternatively put the name of the service and the key in each array names.append(alllines[i][:-1]) - # names.append(thisname) else: keys.append(alllines[i][:-1]) -print(names) -chose=dmenu.show(names,case_insensitive=True, prompt='Search:') -print(chose) +chose=dmenu.show(names,case_insensitive=True, prompt='Search:') #get the selection from the user through dmenu + for i in range(0,len(keys)): if chose==names[i]: totp = pyotp.TOTP(keys[i]) - print(totp.now()) clipboard.copy(totp.now()) + break else: continue