Added a generator for CPAN expressions. Expressions often require manual editing, but still something..

svn path=/nixpkgs/trunk/; revision=11947
This commit is contained in:
Michael Raskin
2008-06-02 08:21:38 +00:00
parent 8b83b37ec5
commit b98a144355
12 changed files with 196 additions and 0 deletions
@@ -0,0 +1,20 @@
#! /bin/sh
source lib-cache.sh
get_file() {
url="$1";
if [ -n "$url" ]; then
curl "$1";
else
echo -n;
fi;
}
url="$1";
name="$2";
name=${name:-$(basename "$url")}
cached_output get_file "${name%%.*}" "$url" "${name#*.}"