From 2f383b303e9ceeeb11c0ac90edf176f64247b568 Mon Sep 17 00:00:00 2001 From: Nemo Date: Wed, 26 May 2021 23:23:38 +0530 Subject: [PATCH] Adds download-as-pdf --- files/bash/.bashrc | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/files/bash/.bashrc b/files/bash/.bashrc index e53af74..43cb1f8 100644 --- a/files/bash/.bashrc +++ b/files/bash/.bashrc @@ -154,6 +154,10 @@ function pingen { pwgen -1Avs -r=qwertyuiopasdfghjklzxcvbnm "$1"; } # Sort a file in-place function sortinplace { sort -o "$1" "$1"; } +function download_as_pdf { + rdrview --template "title,body" "$1" -H | tidy | pandoc --from html --pdf-engine=xelatex -o "$2" +} + # alias kapitan='docker run -t --rm -u $(id -u) -v $(pwd):/src:delegated deepmind/kapitan' # check the window size after each command and, if necessary, # update the values of LINES and COLUMNS.