--- trunk/mage/usr/lib/mage/mage4.sh 2007/01/19 23:15:04 413 +++ trunk/mage/usr/lib/mage/mage4.sh 2010/06/28 17:45:18 1080 @@ -1,6 +1,6 @@ #!/bin/sh # Magellan Linux Installer (mage.sh) -# $Header: /home/cvsd/magellan-cvs/magellan-src/mage/usr/lib/mage/mage4.sh,v 1.15 2007-01-19 23:15:04 niro Exp $ +# $Header: /home/cvsd/magellan-cvs/magellan-src/mage/usr/lib/mage/mage4.sh,v 1.17 2008-06-16 09:29:57 niro Exp $ # default die function die() @@ -15,8 +15,8 @@ source /etc/mage.rc.global || \ die "/etc/mage.rc.global missing" -[ -f /etc/mage.rc ] && source /etc/mage.rc || \ - die "Your /etc/mage.rc is missing. Aborting." +[ -f ${MAGERC} ] && source ${MAGERC} || \ + die "Your ${MAGERC} is missing. Aborting." [ -f ${MLIBDIR}/mage4.functions.sh ] && \ source ${MLIBDIR}/mage4.functions.sh || \ @@ -55,7 +55,7 @@ # sanity checks [ ! -e ${VIRTUALDB_FILE} ] && touch ${VIRTUALDB_FILE} -if [ ! -e ${VIRTUALDB_DEFAULTS} ] && [[ $1 != update ]] +if [ ! -e ${VIRTUALDB_DEFAULTS} ] && [[ $1 != update ]] && [[ $1 != update-tarball ]] then echo echo "Please choose an profile from the mage tree." @@ -83,7 +83,8 @@ echo " install - installs a package" echo " srcinstall - installs a package from source" echo " uninstall - removes a package" - echo " update - updates mage-tree" + echo " update - updates the mage-tree via rsync" + echo " update-tarball - updates the mage-tree via a tarball" echo " uppretend - pretend dependencies for a system upgrade" echo " upgrade - runs a complete system upgrade" echo " srcuppretend - pretend dependencies for a system upgrade from source" @@ -125,6 +126,7 @@ [[ ${METHOD} != uppretend ]] && \ [[ ${METHOD} != srcuppretend ]] && \ [[ ${METHOD} != update ]] && \ + [[ ${METHOD} != update-tarball ]] && \ [[ ${METHOD} != clean ]] && \ [[ ${METHOD} != version ]] && \ [[ ${METHOD} != search ]] && \ @@ -406,6 +408,10 @@ syncmage ;; + update-tarball) + syncmage_tarball + ;; + clean) cleanpkg ;;