[meld/build-updates: 25/26] conf: Make DATADIR and LOCALEDIR always pathlib Paths
- From: Kai Willadsen <kaiw src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [meld/build-updates: 25/26] conf: Make DATADIR and LOCALEDIR always pathlib Paths
- Date: Sun, 11 Sep 2022 02:17:16 +0000 (UTC)
commit 49074cf908507354cf2bccb3698b78845a87f904
Author: Kai Willadsen <kai willadsen gmail com>
Date: Sun Sep 11 12:13:00 2022 +1000
conf: Make DATADIR and LOCALEDIR always pathlib Paths
meld/conf.py.in | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
---
diff --git a/meld/conf.py.in b/meld/conf.py.in
index 311b8a4d..a09a4758 100644
--- a/meld/conf.py.in
+++ b/meld/conf.py.in
@@ -14,8 +14,8 @@ PROFILE = ''
if CONFIGURED == 'True':
APPLICATION_ID = '@application_id@'
- DATADIR = '@pkgdatadir@'
- LOCALEDIR = '@localedir@'
+ DATADIR = Path("@pkgdatadir@")
+ LOCALEDIR = Path("@localedir@")
PROFILE = '@profile@'
__package__ = '@project@'
@@ -49,10 +49,10 @@ def project_version_from_meson(meson_path: Path) -> Tuple[str, str]:
def frozen():
global DATADIR, LOCALEDIR, DATADIR_IS_UNINSTALLED
- melddir = os.path.dirname(sys.executable)
+ melddir = Path(sys.executable).parent
- DATADIR = os.path.join(melddir, "share", "meld")
- LOCALEDIR = os.path.join(melddir, "share", "mo")
+ DATADIR = melddir / "share" / "meld"
+ LOCALEDIR = melddir / "share" / "mo"
DATADIR_IS_UNINSTALLED = True
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]