Print script for wkhtmltopdf

This commit is contained in:
Vadim Makeev 2012-09-23 23:30:41 +02:00
parent 8a43fcdade
commit c1708fd239
1 changed files with 12 additions and 0 deletions

12
scripts/print.sh Executable file
View File

@ -0,0 +1,12 @@
#!/bin/bash
file=$1
name=${file%.*}
echo 'Printing…'
wkhtmltopdf -T 0 -R 0 -B 0 -L 0 --page-width 1024px --page-height 640px --dpi 300 --print-media-type --quiet ${file} ${name}.pdf
echo 'Finished.'
# Usage example: sh print.sh index.html