make the script fit to page images (later i will make it customizable from the web ui)
This commit is contained in:
parent
81642f5973
commit
25fefef893
|
@ -14,20 +14,20 @@ for file in "$1"; do
|
||||||
echo $imagelogmsg
|
echo $imagelogmsg
|
||||||
cp $1 $HOME/imagelog
|
cp $1 $HOME/imagelog
|
||||||
echo "Printing image/document"
|
echo "Printing image/document"
|
||||||
lpr -o portrait -o media=A4 $1 -P $printer # if you are using a different printer that requires different commands to print, change this part of the code.
|
lpr -o portrait -o media=A4 -o fit-to-page $1 -P $printer # if you are using a different printer that requires different commands to print, change this part of the code.
|
||||||
else
|
else
|
||||||
echo "Printing image/document"
|
echo "Printing image/document"
|
||||||
lpr -o portrait -o media=A4 $1 -P $printer # if you are using a different printer that requires different commands to print, change this part of the code.
|
lpr -o portrait -o media=A4 -o fit-to-page $1 -P $printer # if you are using a different printer that requires different commands to print, change this part of the code.
|
||||||
fi
|
fi
|
||||||
elif [[ "$mime_type" == text/* ]]; then
|
elif [[ "$mime_type" == text/* ]]; then
|
||||||
if [[ $2 == log ]]; then
|
if [[ $2 == log ]]; then
|
||||||
echo $imagelogmsg
|
echo $imagelogmsg
|
||||||
cp $1 $HOME/imagelog
|
cp $1 $HOME/imagelog
|
||||||
echo "Printing text"
|
echo "Printing text"
|
||||||
lpr -o portrait -o media=A4 $1 -P $printer # if you are using a different printer that requires different commands to print, change this part of the code.
|
lpr -o portrait -o media=A4 -o fit-to-page $1 -P $printer # if you are using a different printer that requires different commands to print, change this part of the code.
|
||||||
else
|
else
|
||||||
echo "Printing text"
|
echo "Printing text"
|
||||||
lpr -o portrait -o media=A4 $1 -P $printer # if you are using a different printer that requires different commands to print, change this part of the code.
|
lpr -o portrait -o media=A4 -o fit-to-page $1 -P $printer # if you are using a different printer that requires different commands to print, change this part of the code.
|
||||||
fi
|
fi
|
||||||
else
|
else
|
||||||
echo "Error: Invalid file type or, ePrint clone only accepts the following MIME types: text/*, image/*, application/pdf"
|
echo "Error: Invalid file type or, ePrint clone only accepts the following MIME types: text/*, image/*, application/pdf"
|
||||||
|
|
Loading…
Reference in New Issue
Block a user