From 5f34edff090dcd75ac77e4d98c4d8550706eabc8 Mon Sep 17 00:00:00 2001 From: solar Date: Sun, 29 Apr 2007 03:15:05 +0000 Subject: [PATCH] - always keep the non compressed version around svn path=/; revision=396 --- trunk/src/genpkgindex/genpkgindex | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/trunk/src/genpkgindex/genpkgindex b/trunk/src/genpkgindex/genpkgindex index 6c0ca77..16ba219 100644 --- a/trunk/src/genpkgindex/genpkgindex +++ b/trunk/src/genpkgindex/genpkgindex @@ -230,10 +230,13 @@ fp.write("\n") fp.flush() fp.close() if (compress): - os.system("bzip2 .Packages") + os.system("bzip2 < .Packages > .Packages.bz2") os.rename(".Packages.bz2", "Packages.bz2") else: - os.rename(".Packages", "Packages") + if os.path.exists("Packages.bz2"): + os.unlink("Packages.bz2") + +os.rename(".Packages", "Packages") # Clean up stale cache files os.chdir(portage_const.CACHE_PATH+"/xpak") -- 2.26.2