diff --git a/README b/README index 429a38a..d478a42 100644 --- a/README +++ b/README @@ -1,3 +1,5 @@ +Requirements: Python 2.x, with bsddb and twisted packages + Usage: pywallet.py [options] Options: diff --git a/pywallet.py b/pywallet.py index 0bc50ae..1505524 100755 --- a/pywallet.py +++ b/pywallet.py @@ -25,6 +25,7 @@ from twisted.web.static import File from twisted.python import log from datetime import datetime +from subprocess import * max_version = 32500 addrtype = 0 @@ -863,7 +864,7 @@ def keyinfo(sec, keyishex): class WIRoot(resource.Resource): def render_GET(self, request): - header = '

Pywallet Web Interface

CLOSE BITCOIN BEFORE USING!



' + header = '

Pywallet Web Interface

CLOSE BITCOIN BEFORE USE!



' DWForm = '

Dump your wallet:

\ Wallet Directory:
\ @@ -1204,6 +1205,10 @@ if __name__ == '__main__': parser.add_option("--port", dest="port", help="port of web interface (defaults to 8989)") +# parser.add_option("--forcerun", dest="forcerun", +# action="store_true", +# help="run even if pywallet detects bitcoin is running") + (options, args) = parser.parse_args() VIEWS = { @@ -1213,6 +1218,15 @@ if __name__ == '__main__': 'Balance': WIBalance() } +# a=Popen("ps xa | grep ' bitcoin'", shell=True, bufsize=-1, stdout=PIPE).stdout +# aread=a.read() +# nl = aread.count("\n") +# a.close() +# if nl > 2: +# print('Bitcoin seems to be running: \n"%s"'%(aread)) +# if options.forcerun is None: +# exit(0) + if options.web is not None: webport = 8989 if options.port is not None: