texlive: allow to add custom mirrors (#433354)

This commit is contained in:
Connor Baker
2025-08-25 15:48:37 -07:00
committed by GitHub

View File

@@ -41,6 +41,7 @@
biber-ms,
makeFontsConf,
useFixedHashes ? true,
extraMirrors ? [ ],
recurseIntoAttrs,
nixfmt,
}:
@@ -111,25 +112,28 @@ let
# should be switching to the tlnet-final versions
# (https://tug.org/historic/).
mirrors =
if version.final then
[
# tlnet-final snapshot; used when texlive.tlpdb is frozen
# the TeX Live yearly freeze typically happens in mid-March
"http://ftp.math.utah.edu/pub/tex/historic/systems/texlive/${toString version.texliveYear}/tlnet-final"
"ftp://tug.org/texlive/historic/${toString version.texliveYear}/tlnet-final"
]
else
[
# CTAN mirrors
"https://mirror.ctan.org/systems/texlive/tlnet"
# daily snapshots hosted by one of the texlive release managers;
# used for packages that in the meanwhile have been updated or removed from CTAN
# and for packages that have not reached yet the historic mirrors
# please note that this server is not meant for large scale deployment
# https://tug.org/pipermail/tex-live/2019-November/044456.html
# https://texlive.info/ MUST appear last (see tlpdbxz)
"https://texlive.info/tlnet-archive/${version.year}/${version.month}/${version.day}/tlnet"
];
extraMirrors
++ (
if version.final then
[
# tlnet-final snapshot; used when texlive.tlpdb is frozen
# the TeX Live yearly freeze typically happens in mid-March
"http://ftp.math.utah.edu/pub/tex/historic/systems/texlive/${toString version.texliveYear}/tlnet-final"
"ftp://tug.org/texlive/historic/${toString version.texliveYear}/tlnet-final"
]
else
[
# CTAN mirrors
"https://mirror.ctan.org/systems/texlive/tlnet"
# daily snapshots hosted by one of the texlive release managers;
# used for packages that in the meanwhile have been updated or removed from CTAN
# and for packages that have not reached yet the historic mirrors
# please note that this server is not meant for large scale deployment
# https://tug.org/pipermail/tex-live/2019-November/044456.html
# https://texlive.info/ MUST appear last (see tlpdbxz)
"https://texlive.info/tlnet-archive/${version.year}/${version.month}/${version.day}/tlnet"
]
);
tlpdbxz = fetchurl {
urls =