From 6b60a5464561bb8840f5cd71b0f404fd7fd4f610 Mon Sep 17 00:00:00 2001 From: Alec Warner Date: Tue, 16 Jan 2007 16:59:34 +0000 Subject: switch news timestamp and unread/read storage to '/var/lib/gentoo' like the GLEP states. svn path=/main/trunk/; revision=5673 --- pym/portage_const.py | 1 + pym/portage_news.py | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) (limited to 'pym') diff --git a/pym/portage_const.py b/pym/portage_const.py index f5b392506..7b44a6c1a 100644 --- a/pym/portage_const.py +++ b/pym/portage_const.py @@ -23,6 +23,7 @@ CUSTOM_PROFILE_PATH = USER_CONFIG_PATH+"/profile" PORTAGE_BASE_PATH = os.path.join(os.sep, os.sep.join(__file__.split(os.sep)[:-2])) PORTAGE_BIN_PATH = PORTAGE_BASE_PATH+"/bin" PORTAGE_PYM_PATH = PORTAGE_BASE_PATH+"/pym" +NEWS_LIB_PATH = "/var/lib/gentoo" PROFILE_PATH = "/etc/make.profile" LOCALE_DATA_PATH = PORTAGE_BASE_PATH+"/locale" diff --git a/pym/portage_news.py b/pym/portage_news.py index 7624bed2d..50da11f8d 100644 --- a/pym/portage_news.py +++ b/pym/portage_news.py @@ -3,7 +3,7 @@ # Distributed under the terms of the GNU General Public License v2 # $Id$ -from portage_const import PRIVATE_PATH, INCREMENTALS, PROFILE_PATH +from portage_const import INCREMENTALS, PROFILE_PATH, NEWS_LIB_PATH from portage import config, vartree, vardbapi, portdbapi from portage_util import ensure_dirs from portage_data import portage_gid @@ -29,7 +29,7 @@ class NewsManager(object): def __init__( self, root, NEWS_PATH, UNREAD_PATH, LANGUAGE_ID='en' ): self.NEWS_PATH = NEWS_PATH self.UNREAD_PATH = UNREAD_PATH - self.TIMESTAMP_PATH = os.path.join( root, PRIVATE_PATH, NewsManager.TIMESTAMP_FILE ) + self.TIMESTAMP_PATH = os.path.join( root, self.NEWS_LIB_PATH, NewsManager.TIMESTAMP_FILE ) self.target_root = root self.LANGUAGE_ID = LANGUAGE_ID self.config = config( config_root = os.environ.get("PORTAGE_CONFIGROOT", "/"), -- cgit v1.2.3-1-g7c22