diff --git a/jwt_tool.py b/jwt_tool.py index 99ca1ab..9741fe2 100644 --- a/jwt_tool.py +++ b/jwt_tool.py @@ -1889,7 +1889,11 @@ def printLogo(): if not args.bare: printLogo() try: - path = os.path.expanduser("~/.jwt_tool") + xdg_config_home = os.environ.get("XDG_CONFIG_HOME", False) + if xdg_config_home: + path = os.path.expanduser(os.path.normpath(xdg_config_home + "/jwt_tool")) + else: + path = os.path.expanduser("~/.jwt_tool") if not os.path.exists(path): os.makedirs(path) except: