#!/bin/sh
#
# $1 - file to print
# $2 - "" or printer-id (main.ini must contain line "prt_${2}=...")
#

prtSwitch='@@@^32PRINTER-SWITCH^@@@'
# NOTE: prtSwitch variable MUST BE the same as in main.ini file

echo -ne "\033[5i"
if [ ! -z "$2" ]; then
    echo -ne "${prtSwitch}${2}\n"
fi
cat "$1"
echo -ne "\033[4i"
