nixpkgs/pkgs/development/perl-modules/expression-generator/source-download-link.sh
Victor Engmark 57b496ea98 misc: Replace tab indentation with spaces
I've tried to be consistent, using four or eight spaces to line up
with existing code.
2021-11-14 16:04:46 +13:00

17 lines
388 B
Bash
Executable file

#! /bin/sh
source lib-cache.sh;
module_name="$1";
module_basename="${module_name//::/-}";
write_link() {
module_basename="$1";
./retrieve-modulepage.sh "$module_basename" |
grep -A 2 "This Release" |
grep href |
sed -re 's/.*href="//; s/".*//; s@^/@http://search.cpan.org/@';
}
cached_output write_link "$module_basename" "$module_basename" src.link;