From dd9b0c60d3b663380debe16d0bf68726df04f9aa Mon Sep 17 00:00:00 2001 From: Felix Pankratz Date: Thu, 8 Jun 2023 16:37:15 +0200 Subject: [PATCH] pretty print --- ip.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ip.py b/ip.py index 229cc99..2bdabbe 100755 --- a/ip.py +++ b/ip.py @@ -18,7 +18,7 @@ def main(): gi = pygeoip.GeoIP('GeoLiteCity.dat') geo_info = gi.record_by_addr(client_ip) geo_info['ip'] = client_ip - print(json.dumps(geo_info)) + print(json.dumps(geo_info, indent=2)) else: print(client_ip)