Update 51-ocr

This commit is contained in:
Alexandre
2021-11-05 11:14:25 +01:00
committed by GitHub
parent 10a57a3cbb
commit ff11ff29a0

View File

@@ -8,8 +8,8 @@ if bashio::config.has_value 'OCR'; then
# Install additional language if requested
if bashio::config.has_value 'OCRLANG'; then
LANG=$(bashio::config 'OCRLANG')
apk add --quiet --no-cache tesseract-ocr-data-$LANG || apk add --quiet --no-cache tesseract-ocr-data-$LANG@community
bashio::log.info "OCR Language installed : $LANG"
apk add --quiet --no-cache tesseract-ocr-data-$LANG || apk add --quiet --no-cache tesseract-ocr-data-$LANG@community \
&& bashio::log.info "OCR Language installed : $LANG" || bashio::log.fatal "Couldn't install OCR lang $LANG. Please check its format is conform"
fi
elif $(bashio::config 'OCR') = false; then
bashio::log.info 'Removing OCR'