From a1b74d382a72573acf3eae1c467d0735786aa3ee Mon Sep 17 00:00:00 2001 From: Frank Haun Date: Tue, 1 Jul 2014 15:41:23 +0200 Subject: __init__.py: Fix include_paths default. --- py3status/__init__.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/py3status/__init__.py b/py3status/__init__.py index e453cda..6f6d172 100755 --- a/py3status/__init__.py +++ b/py3status/__init__.py @@ -590,11 +590,14 @@ class Py3statusWrapper(): """ Create the py3status based on command line options we received. """ + # get home path + home = '{}{}'.format(os.path.expanduser('~'), '/') + # defaults config = { 'cache_timeout': 60, 'i3status_config_path': '/etc/i3status.conf', - 'include_paths': ['.i3/py3status/'], + 'include_paths': ['{}{}'.format(home, '.i3/py3status/')], 'interval': 1 } @@ -620,7 +623,7 @@ class Py3statusWrapper(): parser.add_argument('-i', action="append", dest="include_paths", help="""include user-written modules from those - directories (default .i3/py3status)""") + directories (default ~/.i3/py3status)""") parser.add_argument('-n', action="store", dest="interval", type=float, -- cgit v1.3 From 7610a9f6ece43b96b10cf5843e300178c0ef55d8 Mon Sep 17 00:00:00 2001 From: Frank Haun Date: Wed, 2 Jul 2014 01:20:23 +0200 Subject: Variable renamed, home -> home_path --- py3status/__init__.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/py3status/__init__.py b/py3status/__init__.py index 6f6d172..4d26ca2 100755 --- a/py3status/__init__.py +++ b/py3status/__init__.py @@ -591,13 +591,13 @@ class Py3statusWrapper(): Create the py3status based on command line options we received. """ # get home path - home = '{}{}'.format(os.path.expanduser('~'), '/') + home_path = '{}{}'.format(os.path.expanduser('~'), '/') # defaults config = { 'cache_timeout': 60, 'i3status_config_path': '/etc/i3status.conf', - 'include_paths': ['{}{}'.format(home, '.i3/py3status/')], + 'include_paths': ['{}{}'.format(home_path, '.i3/py3status/')], 'interval': 1 } -- cgit v1.3