From 0c17b53d2e6790e5c47856b694db0cdd22b6e889 Mon Sep 17 00:00:00 2001 From: Don Allingham Date: Wed, 29 Mar 2006 04:46:26 +0000 Subject: [PATCH] remove expanduser svn: r6220 --- gramps2/src/ArgHandler.py | 7 +++---- gramps2/src/BaseDoc.py | 2 +- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/gramps2/src/ArgHandler.py b/gramps2/src/ArgHandler.py index 516f5bf15..a0bd8dd79 100644 --- a/gramps2/src/ArgHandler.py +++ b/gramps2/src/ArgHandler.py @@ -337,9 +337,8 @@ class ArgHandler: #self.parent.cl = bool(self.exports or self.actions or self.parent.cl) # Create dir for imported database(s) - self.impdir_path = os.path.expanduser("~/.gramps/import" ) - self.imp_db_path = os.path.expanduser( - "~/.gramps/import/import_db.grdb" ) + self.impdir_path = os.path.join(const.home_dir,"import" ) + self.imp_db_path = os.path.join(self.impdir_path, "import_db.grdb" ) if not os.path.isdir(self.impdir_path): try: os.mkdir(self.impdir_path,0700) @@ -437,7 +436,7 @@ class ArgHandler: os._exit(1) elif format == 'gramps-pkg': # Create tempdir, if it does not exist, then check for writability - tmpdir_path = os.path.expanduser("~/.gramps/tmp" ) + tmpdir_path = os.path.join(const.home_dir,"tmp") if not os.path.isdir(tmpdir_path): try: os.mkdir(tmpdir_path,0700) diff --git a/gramps2/src/BaseDoc.py b/gramps2/src/BaseDoc.py index 2e9bd3495..b372004fb 100644 --- a/gramps2/src/BaseDoc.py +++ b/gramps2/src/BaseDoc.py @@ -798,7 +798,7 @@ class StyleSheetList: """ defstyle.set_name('default') self.map = { "default" : defstyle } - self.file = os.path.expanduser("~/.gramps/" + file) + self.file = os.path.join(const.home_dir,file) self.parse() def delete_style_sheet(self,name):