Re:The Emacs Lock-In Effect or the Emacs Sunk Cost Fallacy
by remexre on Friday August 06, 2021 @07:53PM
(#28094195)
How do you do package (version) management for LaTeX? There's more than a few documents I've come across that won't build on my system, giving often-indecipherable compilation errors. Overleaf at least ensures everyone involved is using the same environment without needing to ship a Docker container or the like, or try to pin down versions.
[ Parent
| on HN ]
Re:The Emacs Lock-In Effect or the Emacs Sunk Cost Fallacy
by Filligree on Friday August 06, 2021 @10:14PM
(#28095069)
Nix has a decent solution here, i.e. turn the document into a nix derivation.
with import <nixpkgs> {};
pkgs.runCommand "cv.pdf" rec {
src = ./cv.tex;
bin = with pkgs.texlive; combine {
inherit scheme-medium collection-latexrecommended collection-fontsextra
moderncv etoolbox;
};
buildInputs = [ bin ];
allowSubstitutes = false;
} ''
ln -s $src cv.tex
latexmk -pdf cv.tex
mkdir $out
mv *pdf $out/
''
These days I'd probably use flakes to pin down the latex version.
Re:The Emacs Lock-In Effect or the Emacs Sunk Cost Fallacy
by eulgro on Friday August 06, 2021 @09:35PM
(#28094871)
I suppose it should be fairly portable, except for missing packages maybe. In my case I have literally every common package installed so that's not an issue. But LaTeX errors are a real pain, I'll admit that.