#!/usr/bin/env bash

script_dir="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" || exit 1
cd "$script_dir/.." || exit 1

./dxprint -auto-configure-device
dxprint_exit=$?
printf '\n'
if (( dxprint_exit != 0 )); then
    printf 'Configurarea automata a esuat. Cod iesire: %s\n' "$dxprint_exit"
fi
read -r -p "Apasa Enter pentru a inchide..." _
exit "$dxprint_exit"
