data home

This commit is contained in:
j 2016-06-06 19:34:12 +02:00
parent 18aebe76d3
commit 4bc6155c3f
1 changed files with 2 additions and 1 deletions

View File

@ -173,7 +173,8 @@ if __name__ == '__main__':
if sys.platform == 'darwin':
target = os.path.expanduser('~/Library/Application Support/Open Media Libary')
elif sys.platform.startswith('linux'):
target = os.path.expanduser('~/.local/share/openmedialibrary')
data_home = os.path.expanduser(os.environ.get('XDG_DATA_HOME', '~/.local/share'))
target = os.path.join(data_home, 'openmedialibrary')
else:
target = os.path.join(os.curdir, 'openmedialibrary')
elif len(sys.argv) != 2: