1 # Elpa only serves the latest version of a given package uncompressed.
2 # Once that release is no longer the latest & greatest it gets archived and compressed
3 # meaning that both the URL and the hash changes.
5 # To work around this issue we fall back to the URL with the .lz suffix and if that's the
6 # one we downloaded we uncompress the file to ensure the hash matches regardless of compression.
10 { url, ... }@args: fetchurl ((removeAttrs args [ "url" ]) // {
16 if [[ $url == *.lz ]]; then
17 ${lzip}/bin/lzip -c -d $out > uncompressed