From 6751d23c7954d2fe3155802fb04ae4e1432e7609 Mon Sep 17 00:00:00 2001 From: flatfly Date: Sun, 1 Dec 2013 09:42:22 +0100 Subject: [PATCH] added getversion command --- lib/commands.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/lib/commands.py b/lib/commands.py index 2cf1996a..3b22dda0 100644 --- a/lib/commands.py +++ b/lib/commands.py @@ -67,6 +67,7 @@ register_command('dumpprivkeys', 0, 0, False, True, True, 'dump all pr register_command('freeze', 1, 1, False, True, True, 'Freeze the funds at one of your wallet\'s addresses', 'freeze
') register_command('getbalance', 0, 1, True, True, False, 'Return the balance of your wallet, or of one account in your wallet', 'getbalance []') register_command('getservers', 0, 0, True, False, False, 'Return the list of available servers') +register_command('getversion', 1, 1, False, False, False, 'Return the version of your client', 'getversion') register_command('getaddressbalance', 1, 1, True, True, False, 'Return the balance of an address', 'getbalance
') register_command('getaddresshistory', 1, 1, True, True, False, 'Return the transaction history of a wallet address', 'getaddresshistory
') register_command('getconfig', 1, 1, False, False, False, 'Return a configuration variable', 'getconfig ') @@ -207,6 +208,10 @@ class Commands: def getservers(self): return self.network.get_servers() + def getversion(): + import electrum + return electrum.ELECTRUM_VERSION + def getmpk(self): return self.wallet.get_master_public_key()