Add ironclad

This commit is contained in:
Michael Raskin
2014-11-16 19:57:12 +03:00
parent 2f53f2ed16
commit 47ae07c56e
3 changed files with 30 additions and 4 deletions
@@ -130,20 +130,21 @@ url="${ql_src##* }"
}
[ "$ql_src_type" = froydware-http ] && {
dirurl = "http://method-combination.net/lisp/files/";
url="$("$(dirname "$0")/../../../build-support/upstream-updater/urls-from-page.sh" "$dirurl" | grep "/$url_" | tail -n 1)"
dirurl="http://method-combination.net/lisp/files/";
url="$("$(dirname "$0")/../../../build-support/upstream-updater/urls-from-page.sh" "$dirurl" |
grep "/${url}_" | grep -v "[.]asc\$" | tail -n 1)"
ql_src_type=http
}
[ "$ql_src_type" = http ] && {
fetcher="pkgs.fetchurl";
version="$(echo "$url" | sed -re 's@.*-([0-9.]+)[-._].*@\1@')"
version="$(echo "$url" | sed -re 's@.*[-_]([0-9.]+)[-._].*@\1@')"
hash="$(nix-prefetch-url "$url" | grep . | tail -n 1)"
}
[ "$ql_src_type" = https ] && {
fetcher="pkgs.fetchurl";
version="$(echo "$url" | sed -re 's@.*-([0-9.]+)[-._].*@\1@')"
version="$(echo "$url" | sed -re 's@.*[-_]([0-9.]+)[-._].*@\1@')"
hash="$(nix-prefetch-url "$url" | grep . | tail -n 1)"
}