diff options
author | Florent Le Coz <louiz@louiz.org> | 2011-06-20 00:26:23 +0200 |
---|---|---|
committer | Florent Le Coz <louiz@louiz.org> | 2011-06-20 00:26:23 +0200 |
commit | 3c120b3aa23456c0a0d2ca8c7edff2f51772ddf7 (patch) | |
tree | b55c0b9a7c210a22080cbafe7d36e4fbcf697ea0 /src/config.py | |
parent | 6ed46d1fe39620b776f08ce08280fac46f5929a0 (diff) | |
parent | f4c24380466fa54924a925a12817e28d603fd4d1 (diff) | |
download | poezio-3c120b3aa23456c0a0d2ca8c7edff2f51772ddf7.tar.gz poezio-3c120b3aa23456c0a0d2ca8c7edff2f51772ddf7.tar.bz2 poezio-3c120b3aa23456c0a0d2ca8c7edff2f51772ddf7.tar.xz poezio-3c120b3aa23456c0a0d2ca8c7edff2f51772ddf7.zip |
merge
Diffstat (limited to 'src/config.py')
-rw-r--r-- | src/config.py | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/config.py b/src/config.py index 4776e7d3..9cedcac7 100644 --- a/src/config.py +++ b/src/config.py @@ -134,18 +134,18 @@ class Config(RawConfigParser): # and copy the default config in it CONFIG_HOME = environ.get("XDG_CONFIG_HOME") if not CONFIG_HOME: - CONFIG_HOME = environ.get('HOME')+'/.config' -CONFIG_PATH = CONFIG_HOME + '/poezio/' + CONFIG_HOME = path.join(environ.get('HOME'), '.config') +CONFIG_PATH = path.join(CONFIG_HOME, 'poezio') try: makedirs(CONFIG_PATH) except OSError: pass -if not path.isfile(CONFIG_PATH+'poezio.cfg'): - copy2(path.join(path.dirname(__file__), '../data/default_config.cfg'), CONFIG_PATH+'poezio.cfg') +if not path.isfile(path.join(CONFIG_PATH, 'poezio.cfg')): + copy2(path.join(path.dirname(__file__), '../data/default_config.cfg'), path.join(CONFIG_PATH, 'poezio.cfg')) parser = OptionParser() -parser.add_option("-f", "--file", dest="filename", default=CONFIG_PATH+'poezio.cfg', +parser.add_option("-f", "--file", dest="filename", default=path.join(CONFIG_PATH, 'poezio.cfg'), help="The config file you want to use", metavar="CONFIG_FILE") parser.add_option("-d", "--debug", dest="debug", help="The file where debug will be written", metavar="DEBUG_FILE") |