diff options
Diffstat (limited to 'accounts/gkleen@sif/utils/pdf2pdf.nix')
-rw-r--r-- | accounts/gkleen@sif/utils/pdf2pdf.nix | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/accounts/gkleen@sif/utils/pdf2pdf.nix b/accounts/gkleen@sif/utils/pdf2pdf.nix new file mode 100644 index 00000000..aba897f0 --- /dev/null +++ b/accounts/gkleen@sif/utils/pdf2pdf.nix | |||
@@ -0,0 +1,8 @@ | |||
1 | pkgs@{ lib, resholve, zsh, ghostscript, ... }: | ||
2 | |||
3 | resholve.writeScriptBin "pdf2pdf" { | ||
4 | inputs = with pkgs; [ghostscript]; | ||
5 | interpreter = lib.getExe zsh; | ||
6 | } '' | ||
7 | exec gs -dPDFSETTINGS=/prepress -dNOPAUSE -dBATCH -sDEVICE=pdfwrite -dSAFER "-sOutputFile=''${2}" "''${1}" | ||
8 | '' | ||