Annotation of /branches/mage-next/src/up2date/gnu.sh.in
Parent Directory | Revision Log
Revision 2591 -
(hide annotations)
(download)
Tue Mar 4 08:35:27 2014 UTC (10 years, 3 months ago) by niro
File size: 368 byte(s)
Tue Mar 4 08:35:27 2014 UTC (10 years, 3 months ago) by niro
File size: 368 byte(s)
-split function into single includes
1 | niro | 2591 | updatecmd_gnu() |
2 | { | ||
3 | local pname=$1 | ||
4 | local archive | ||
5 | local tarball | ||
6 | |||
7 | [[ -z ${pname} ]] && die "give me a \$PNAME" | ||
8 | [[ ! -z $2 ]] && archive="$2" | ||
9 | |||
10 | tarball="${pname}" | ||
11 | [[ ! -z ${UP2TARBALL} ]] && tarball="${UP2TARBALL}" | ||
12 | |||
13 | # remove 'latest' tarball too | ||
14 | updatecmd "http://ftp.gnu.org/gnu/${pname}/?C=M;O=A" | grep ${tarball}- | sed '/latest/d' | lasttarball "${archive}" | ||
15 | } |