pkgs@{ lib, resholve, zsh, ghostscript_headless, ... }: resholve.writeScriptBin "pdf2pdf" { inputs = with pkgs; [ghostscript_headless]; interpreter = lib.getExe zsh; } '' exec gs -dPDFSETTINGS=/prepress -dNOPAUSE -dBATCH -sDEVICE=pdfwrite -dSAFER "-sOutputFile=''${2}" "''${1}" ''