summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xbuild_tools/bin/mp.py13
1 files changed, 8 insertions, 5 deletions
diff --git a/build_tools/bin/mp.py b/build_tools/bin/mp.py
index fe8459b..18a4f2c 100755
--- a/build_tools/bin/mp.py
+++ b/build_tools/bin/mp.py
@@ -1,5 +1,5 @@
#!/usr/bin/env python2
-# Version 0.6.3
+# Version 0.6.4
import os
import sys
@@ -214,7 +214,7 @@ def update_repo():
os.chdir(DOCROOT)
print
- print "INFO: Changed working dir to ",DOCROOT
+ print "INFO: Changed working dir to",DOCROOT
print
for i in pkglist:
@@ -226,10 +226,12 @@ def update_repo():
print "ERROR in function update_repo: Couldn't find the new package ",TOTALPKG
sys.exit(2)
# Remove old package from local copy
- OLDPKG = glob.glob(i + "-" + pkgver + "-*-" + CARCH + ".pkg.tar.*z")
+ ## FIX ME
+ ## This only works is the pkgver of the old pkg is the same as the new.
+ OLDPKG = glob.glob(i + "-" + pkgver + "-*-" + CARCH + ".pkg.tar.*z")
if OLDPKG:
DELPKG = OLDPKG.pop()
- print "DELPKG:",DELPKG
+ print "Deleting old package:",DELPKG
os.remove(DELPKG)
# Remove any symlinks to old packages
# We make it conditional on "--force" because force will overwrite
@@ -240,7 +242,8 @@ def update_repo():
os.remove(mydir + "/" + DELPKG)
# Copy in new package
print "############################################"
- print "Updating " + DOCROOT + "/" + CARCH + "/" + REPO + " with " + TOTALPKG
+ print "Updating " + DOCROOT + " with " + TOTALPKG
+ print "Copying " + PKGDEST + "/" + TOTALPKG
shutil.copy2(PKGDEST + "/" + TOTALPKG, DOCROOT)
subprocess.call(["repo-add", DOCROOT+ "/" + REPO + ".db.tar.gz", DOCROOT + "/" + TOTALPKG])
print "############################################"