Pin nixpkgs to the revision used by itc.componentware: the channel version ships a latexminted that crashes on Python 3.14, which made every listing fail and sent latexmk into an endless error prompt. Also force nonstopmode/halt-on-error so a broken listing can never loop again.
50 lines
1.2 KiB
Nix
50 lines
1.2 KiB
Nix
let
|
|
# Pinned to the same nixpkgs revision as itc.componentware, where the minted
|
|
# toolchain is known to work. The channel version ships a latexminted that
|
|
# crashes on Python 3.14, which makes every code listing fail.
|
|
pkgs = import (builtins.fetchTarball {
|
|
url = "https://github.com/NixOS/nixpkgs/archive/cc3f2ee0b3909e42334f34720ccac109a7e67068.tar.gz";
|
|
sha256 = "sha256:0lz0yl9fmh5wfqp7j7rmcs8qjqr3bf1h5cy4rfdasbnbzh4k9j6x";
|
|
}) {};
|
|
|
|
fonts = [
|
|
pkgs.times-newer-roman
|
|
];
|
|
in
|
|
pkgs.mkShell {
|
|
nativeBuildInputs = fonts;
|
|
packages = with pkgs; [
|
|
latexrun
|
|
mermaid-cli
|
|
times-newer-roman
|
|
(texlive.withPackages (ps:
|
|
with ps; [
|
|
transparent
|
|
times
|
|
hyphenat
|
|
changepage
|
|
biblatex
|
|
listings
|
|
minted
|
|
upquote
|
|
biber
|
|
fontaxes
|
|
newtxtt
|
|
newtx
|
|
newtxsf
|
|
csquotes
|
|
enumitem
|
|
titlesec
|
|
latexmk
|
|
scheme-medium
|
|
textpos
|
|
]))
|
|
];
|
|
shellHook = ''
|
|
# install fonts
|
|
DEST=~/.local/share/fonts/TimesNewerRoman
|
|
mkdir -p $DEST
|
|
cp -rn ${toString pkgs.times-newer-roman}/share/fonts/opentype "$DEST" 2>/dev/null || true
|
|
'';
|
|
}
|