Skip to content

Commit

Permalink
xdg was changed to xdg_base_dirs to avoid namespace collision
Browse files Browse the repository at this point in the history
  • Loading branch information
kjmeagher committed Oct 4, 2023
1 parent 3441e7c commit c368486
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 3 deletions.
4 changes: 2 additions & 2 deletions multizone.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@

import tabulate
import tzlocal
import xdg
from xdg_base_dirs import xdg_config_home
from babel.core import default_locale
from babel.dates import format_datetime
from termcolor import colored
Expand Down Expand Up @@ -123,7 +123,7 @@ def parse_args() -> argparse.Namespace:
def load_config(config_path: Path | None) -> ConfigType:
"""Read toml configuration file from given path or default path."""
if config_path is None:
config_filename = xdg.xdg_config_home() / "multizone" / "multizone.toml"
config_filename = xdg_config_home() / "multizone" / "multizone.toml"
if not config_filename.is_file():
config_filename = None
else:
Expand Down
10 changes: 9 additions & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,15 @@ classifiers = [
"Programming Language :: Python :: 3.11",
"Topic :: Utilities"
]
dependencies = ["backports.zoneinfo; python_version < '3.9'", "babel", "tabulate", "tzlocal", "xdg", "termcolor", "tomli; python_version < '3.11'"]
dependencies = [
"backports.zoneinfo; python_version < '3.9'",
"babel",
"tabulate",
"tzlocal",
"xdg-base-dirs",
"termcolor",
"tomli; python_version < '3.11'"
]
dynamic = ["version", "description"]
license = {file = "COPYING"}
name = "multizone"
Expand Down

0 comments on commit c368486

Please sign in to comment.