tangled
alpha
login
or
join now
pyrox.dev
/
nixpkgs
0
fork
atom
lol
0
fork
atom
overview
issues
pulls
pipelines
lhadpdf.pdf_sets: update maintainer.sh
Dmitry Kalinkin
5 years ago
92ac87f0
36991a8f
+5
-3
1 changed file
expand all
collapse all
unified
split
pkgs
development
libraries
physics
lhapdf
maintainer.sh
+5
-3
pkgs/development/libraries/physics/lhapdf/maintainer.sh
···
1
1
#!/bin/bash
2
2
3
3
-
set -e
3
3
+
set -xe
4
4
5
5
-
BASE_URL="https://lhapdf.hepforge.org/downloads?f=pdfsets/6.2/"
5
5
+
: ${SED:="$(nix-build '<nixpkgs>' -A gnused --no-out-link)/bin/sed"}
6
6
7
7
-
for pdf_set in `curl $BASE_URL 2>/dev/null | gsed -e "s/.*<a href=\"[^\"]*\/\([^\"/]*.tar.gz\)\".*/\1/;tx;d;:x" | gsed -e "s/%2B/+/g" | sort -u`; do
7
7
+
BASE_URL="https://lhapdfsets.web.cern.ch/lhapdfsets/current/"
8
8
+
9
9
+
for pdf_set in `curl -L $BASE_URL 2>/dev/null | "$SED" -e "s/.*<a href=\"\([^\"/]*.tar.gz\)\".*/\1/;tx;d;:x" | sort -u`; do
8
10
echo -n " \"${pdf_set%.tar.gz}\" = \""
9
11
nix-prefetch-url "${BASE_URL}${pdf_set}" 2>/dev/null | tr -d '\n'
10
12
echo "\";"