From b6c049019a470f8fcd9c438e460d8e54535aa184 Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Fri, 7 Jul 2017 17:12:25 +0200 Subject: [PATCH] mirror-nixos-branch.pl: Call index-debuginfo --- mirror-nixos-branch.pl | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/mirror-nixos-branch.pl b/mirror-nixos-branch.pl index 5027855..6132a89 100755 --- a/mirror-nixos-branch.pl +++ b/mirror-nixos-branch.pl @@ -149,12 +149,15 @@ if ($bucket->head_key("$releasePrefix")) { downloadFile("tarball", "nixexprs.tar.xz"); } - # Generate the programs.sqlite database and put it in nixexprs.tar.xz. + # Generate the programs.sqlite database and put it in + # nixexprs.tar.xz. Also maintain the debug info repository at + # https://cache.nixos.org/debuginfo. if ($channelName =~ /nixos/ && -e "$tmpDir/store-paths") { File::Path::make_path("$tmpDir/unpack"); system("tar", "xfJ", "$tmpDir/nixexprs.tar.xz", "-C", "$tmpDir/unpack") == 0 or die; my $exprDir = glob("$tmpDir/unpack/*"); system("generate-programs-index $filesCache $exprDir/programs.sqlite http://nix-cache.s3.amazonaws.com/ $tmpDir/store-paths $exprDir/nixpkgs") == 0 or die; + system("index-debuginfo $filesCache s3://nix-cache $tmpDir/store-paths") == 0 or die; system("rm -f $tmpDir/nixexprs.tar.xz $exprDir/programs.sqlite-journal") == 0 or die; unlink("$tmpDir/nixexprs.tar.xz.sha256"); system("tar", "cfJ", "$tmpDir/nixexprs.tar.xz", "-C", "$tmpDir/unpack", basename($exprDir)) == 0 or die;