summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJames Meyer <james.meyer@operamail.com>2009-01-10 19:58:10 (GMT)
committerJames Meyer <james.meyer@operamail.com>2009-01-10 19:58:10 (GMT)
commit15ec3eb14ba833e671cc8b84ae47db55b9c6cf07 (patch)
tree0730b7572daf7e9cd3cfa3404ca08bf27131f508
parente8f9c5390187d11d01f868c34beee034b91b72a3 (diff)
downloadlinhes_dev-15ec3eb14ba833e671cc8b84ae47db55b9c6cf07.zip
switch back to using unison.
This time it will force an update with the assumption the local pkg.db.tar.gz is always correct.
-rw-r--r--build_tools/bin/km-up.prf2
-rwxr-xr-xbuild_tools/bin/kmsync.sh16
2 files changed, 14 insertions, 4 deletions
diff --git a/build_tools/bin/km-up.prf b/build_tools/bin/km-up.prf
index 9fa6ce4..73a3cf9 100644
--- a/build_tools/bin/km-up.prf
+++ b/build_tools/bin/km-up.prf
@@ -3,4 +3,4 @@
ignore = Name .*~
ignore = Name *.o
ignore = Name *.tmp
- ignore = Name *.db.tar.gz.old
+ ignore = Name *.pkg.tar.gz
diff --git a/build_tools/bin/kmsync.sh b/build_tools/bin/kmsync.sh
index f8e9168..6da7f11 100755
--- a/build_tools/bin/kmsync.sh
+++ b/build_tools/bin/kmsync.sh
@@ -14,10 +14,10 @@ fi
cwd=`dirname $0`
REMOTE_DIR=/mount/repository/repo
DOCROOT=/data/pkg_repo/$CARCH
-
#export UNISON="/root/.unison"
export UNISON="/data/pkg_repo/.unison"
-
+cp -f /build_tools/bin/km-up.prf $UNISON/km-up.prf
+cp -f /build_tools/bin/km-down.prf $UNISON/km-down.prf
function sync_dirs {
REMOTE=$1
LOCAL=$2
@@ -26,6 +26,11 @@ function sync_dirs {
echo "________________________________________________________"
#first bring down new changes from knoppmyth.net
+ echo "--------"
+ echo
+ echo "Syncing the packages with knoppmyth.net"
+ echo
+ echo "--------"
unison km-down -logfile /tmp/unison-down.log -auto -batch -numericids ssh://reposync@knoppmyth.net/$REMOTE $LOCAL
if [ ! $? = 0 ]
@@ -40,8 +45,13 @@ function sync_dirs {
update_db_repo.sh $LOCAL $3
#push the database back
+ echo "--------"
+ echo
echo "Pushing the pkg database to knoppmyth.net"
- scp $LOCAL/*.db.tar.gz reposync@knoppmyth.net:$REMOTE/
+ echo
+ echo "--------"
+ unison km-up -logfile /tmp/unison-up.log -auto -batch -numericids -force $LOCAL $LOCAL ssh://reposync@knoppmyth.net/$REMOTE
+ #scp $LOCAL/*.db.tar.gz reposync@knoppmyth.net:$REMOTE/
echo "-------------------------------------------------------"
echo "----------- Finished with $3 -----------"