summaryrefslogtreecommitdiff
path: root/examples/dhcpleases.py
diff options
context:
space:
mode:
authorPhilipp Hahn <hahn@univention.de>2018-11-20 08:34:48 +0100
committerPhilipp Hahn <pmhahn+github@pmhahn.de>2020-08-05 07:43:02 +0000
commit74a78fa42c7dcf75343909923cc87184107cbd31 (patch)
tree1457e7f419ce53e563631191775a0eede465bb3a /examples/dhcpleases.py
parentb801ff31faf97a616e554ba266783d480e00b781 (diff)
downloadlibvirt-python-74a78fa42c7dcf75343909923cc87184107cbd31.tar.gz
examples: Fix white space
indent by 4 spaces one spaces around assignments Signed-off-by: Philipp Hahn <hahn@univention.de>
Diffstat (limited to 'examples/dhcpleases.py')
-rwxr-xr-xexamples/dhcpleases.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/examples/dhcpleases.py b/examples/dhcpleases.py
index 13049c5..92395c5 100755
--- a/examples/dhcpleases.py
+++ b/examples/dhcpleases.py
@@ -30,6 +30,7 @@ if not leases:
print("Failed to get leases for %s" % net.name())
exit(0)
+
def toIPAddrType(addrType: int) -> str:
if addrType == libvirt.VIR_IP_ADDR_TYPE_IPV4:
return "ipv4"
@@ -37,13 +38,14 @@ def toIPAddrType(addrType: int) -> str:
return "ipv6"
return "Unknown"
+
print(" {0:20} {1:18} {2:9} {3:25} {4:15} {5}".format("Expiry Time",
"MAC address",
"Protocol",
"IP address",
"Hostname",
"Client ID or DUID"))
-print("-"*115)
+print("-" * 115)
for lease in leases:
print(" {0:20} {1:18} {2:9} {3:25} {4:15} {5}".format(