From 17aaf75ec8ef02582cc57de69b8f4d4c0a2e5ae8 Mon Sep 17 00:00:00 2001 From: root Date: Fri, 28 Sep 2018 18:43:55 +0530 Subject: [PATCH] Fixed update method --- pwnedornot.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/pwnedornot.py b/pwnedornot.py index dcf3bf5..2a46876 100755 --- a/pwnedornot.py +++ b/pwnedornot.py @@ -25,7 +25,7 @@ try: except NameError: unicode = str # Python 3 -version = '1.0.9' +version = '1.1.0' def update(): print (G + '[+]' + C + ' Checking for updates...' + W + '\n') @@ -36,8 +36,9 @@ def update(): print (G + '[!]' + C + ' A New Version is Available : ' + W + updated_version) ans = raw_input(G + '[!]' + C + ' Update ? [y/n] : ' + W) if ans == 'y': - print ('\n' + G + '[+]' + C + ' Updating...' + '\n') - subprocess.call(['git', 'pull']) + print ('\n' + G + '[+]' + C + ' Updating...' + '\n' + W) + subprocess.check_output(['git', 'reset', '--hard', 'origin/master']) + subprocess.check_output(['git', 'pull']) print (G + '[+]' + C + ' Script Updated...Please Execute Again...') exit() else: