[Nix-dev] Fetching variable and unpredictable URL download link

Anderson Torres torres.anderson.85 at gmail.com
Sun Mar 1 16:21:04 CET 2015


Hello, Nixers!

How can I "fetchurl" a variable url?

When I download a dockapp from Windowmaker site, like

"http://windowmaker.org/dockapps/?download=wmSMPmon-3.1.tar.gz",

it in fact downloads something like "wmSMPmon-${a long string of
chars, like a checksum}.tar.gz". And the long string is unpredictable.

And when I run nix-prefetch-url
"http://windowmaker.org/dockapps/?download=wmSMPmon-3.1.tar.gz" more
than once, it just outputs different hashes:

> nix-prefetch-url http://windowmaker.org/dockapps/\?download\=wmSMPmon-3.1.tar.gz
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:--  0:00:01 --:--:--     0
100 24113    0 24113    0     0   3809      0 --:--:--  0:00:06 --:--:--  5139
path is ‘/nix/store/lqri8zgmwz3mbf3q07kp62zl81bc6fpq-?download=wmSMPmon-3.1.tar.gz’
104bcfj4j0vlnr4v1fzahgj9amccn1aq7rjcpy1jyqnq6lbrmc3g

> nix-prefetch-url http://windowmaker.org/dockapps/\?download\=wmSMPmon-3.1.tar.gz
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
100 24110    0 24110    0     0   3193      0 --:--:--  0:00:07 --:--:--  3985
path is ‘/nix/store/f2b7rksjfh6ajddjhx09xb0jzc04jxg9-?download=wmSMPmon-3.1.tar.gz’
1s01whvf51jrwdmrk3bdgysaa2rzmh56c9p0kv3ydxijaagvqi2x

How can I download it?


More information about the nix-dev mailing list