Magellan Linux

Diff of /trunk/mage/usr/lib/mage/mage4.functions.sh

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 248 by niro, Tue Sep 27 14:38:01 2005 UTC revision 252 by niro, Sun Oct 2 14:09:41 2005 UTC
# Line 1  Line 1 
1  #!/bin/bash  #!/bin/bash
2  # Magellan Linux Installer Functions (mage.functions.sh)  # Magellan Linux Installer Functions (mage.functions.sh)
3  # $Header: /home/cvsd/magellan-cvs/magellan-src/mage/usr/lib/mage/mage4.functions.sh,v 1.4 2005-09-27 14:38:01 niro Exp $  # $Header: /home/cvsd/magellan-cvs/magellan-src/mage/usr/lib/mage/mage4.functions.sh,v 1.6 2005-10-02 14:09:41 niro Exp $
4    
5  mage_setup()  mage_setup()
6  {  {
# Line 1667  is_newer_mage_version_available() Line 1667  is_newer_mage_version_available()
1667   local newest_mage   local newest_mage
1668   local installed_mage   local installed_mage
1669    
1670   newest_mage="$( CATEGORIE=app-mage MAGENAME=mage get_highest_magefile;echo $(basename ${MAGEFILE} .mage) )"   newest_mage="$(basename $(get_highest_magefile app-mage mage) .mage)"
1671   installed_mage="$(magequery -n mage | cut -d' ' -f5)"   installed_mage="$(magequery -n mage | cut -d' ' -f5)"
1672    
1673   if [[ ${newest_mage} > ${installed_mage} ]]   if [[ ${newest_mage} > ${installed_mage} ]]
# Line 2520  pkgsearch() Line 2520  pkgsearch()
2520   unset ipbuild   unset ipbuild
2521   done   done
2522  }  }
2523    
2524    export_inherits()
2525    {
2526     local include="$1"
2527     shift
2528    
2529     while [ "$1" ]
2530     do
2531     local functions="$1"
2532    
2533     # sanity checks
2534     [ -z "${include}" ] && die "export_inherits(): \$include not given."
2535     [ -z "${functions}" ] && die "export_inherits(): \$functions not given."
2536    
2537     eval "${functions}() { ${include}_${functions} ; }"
2538    
2539     # debug
2540     [[ ${MAGEDEBUG} = on ]] && typeset -f "${functions}"
2541    
2542     shift
2543     done
2544    }

Legend:
Removed from v.248  
changed lines
  Added in v.252