Unixy location is fallback on OS X

This is mainly for backwards compatibility. It's also an effort to reduce the
support burden; this way, I can say "your config directory is ~/.config/beets"
without needing to ascertain whether someone is on a Mac.
This commit is contained in:
Adrian Sampson 2014-02-21 20:57:06 -05:00
parent 129575178c
commit 622ca2b244
2 changed files with 8 additions and 7 deletions

View file

@ -502,14 +502,14 @@ def _package_path(name):
return os.path.dirname(os.path.abspath(filepath))
def config_dirs():
"""Return a list of candidates for user configuration directories
on the system.
"""Return a platform-specific list of candidates for user
configuration directories on the system.
"""
paths = []
if platform.system() == 'Darwin':
paths.append(UNIX_DIR_FALLBACK)
paths.append(MAC_DIR)
paths.append(UNIX_DIR_FALLBACK)
if UNIX_DIR_VAR in os.environ:
paths.append(os.environ[UNIX_DIR_VAR])

View file

@ -8,11 +8,12 @@ every aspect of its operation. To configure beets, you'll edit a file called
* On Unix-like OSes, you want ``~/.config/beets/config.yaml``.
* On Windows, use ``%APPDATA%\beets\config.yaml``. This is usually in a
directory like ``C:\Users\You\AppData\Roaming``.
* On OS X, it is ``~/Library/Application Support/beets/config.yaml``.
* On OS X, you can use either the Unix location or ``~/Library/Application
Support/beets/config.yaml``.
It is also possible to customize the location of the configuration file
and even use multiple layers of configuration. Just have a look at
`Configuration Location`_.
It is also possible to customize the location of the configuration file and
even use multiple layers of configuration. See `Configuration Location`_,
below.
The config file uses `YAML`_ syntax. You can use the full power of YAML, but
most configuration options are simple key/value pairs. This means your config