mirror of
https://github.com/alexbelgium/hassio-addons.git
synced 2026-05-30 20:34:04 +02:00
hadolint
This commit is contained in:
@@ -1,17 +1,17 @@
|
||||
#!/usr/bin/with-contenv bashio
|
||||
# shellcheck shell=bash
|
||||
|
||||
slug=paperless
|
||||
|
||||
|
||||
if [ ! -d /config/addons_config/$slug ]; then
|
||||
|
||||
if [ -d /config/$slug ]; then
|
||||
echo "Moving to new location /config/addons_config/$slug"
|
||||
mkdir -p /config/addons_config/$slug
|
||||
chmod 777 /config/addons_config/$slug
|
||||
mv /config/$slug/* /config/addons_config/$slug/
|
||||
rm -r /config/$slug
|
||||
fi
|
||||
if [ -d /config/$slug ]; then
|
||||
echo "Moving to new location /config/addons_config/$slug"
|
||||
mkdir -p /config/addons_config/$slug
|
||||
chmod 777 /config/addons_config/$slug
|
||||
mv /config/$slug/* /config/addons_config/$slug/
|
||||
rm -r /config/$slug
|
||||
fi
|
||||
|
||||
echo "Creating /config/addons_config/$slug"
|
||||
mkdir -p /config/addons_config/$slug
|
||||
|
||||
@@ -1,13 +1,14 @@
|
||||
#!/usr/bin/with-contenv bashio
|
||||
# shellcheck shell=bash
|
||||
|
||||
echo "Installing pikepdf..."
|
||||
(
|
||||
export DEBIAN_FRONTEND="noninteractive"
|
||||
export TERM="xterm-256color"
|
||||
apt-get update
|
||||
apt-get install -yq libxml2-dev libxslt-dev python-dev
|
||||
apt-get install -yq libjpeg-dev zlib1g-dev
|
||||
apt-get install -yq python3-dev build-essential
|
||||
pip install pikepdf --force-reinstall
|
||||
export DEBIAN_FRONTEND="noninteractive"
|
||||
export TERM="xterm-256color"
|
||||
apt-get update
|
||||
apt-get install -yq libxml2-dev libxslt-dev python-dev
|
||||
apt-get install -yq libjpeg-dev zlib1g-dev
|
||||
apt-get install -yq python3-dev build-essential
|
||||
pip install pikepdf --force-reinstall
|
||||
) >/dev/null
|
||||
echo "... success!"
|
||||
echo "... success!"
|
||||
|
||||
@@ -1,11 +1,12 @@
|
||||
#!/usr/bin/with-contenv bashio
|
||||
# shellcheck shell=bash
|
||||
|
||||
OCRLANG=$(bashio::config 'OCRLANG')
|
||||
if [ -n "$OCRLANG" ]; then
|
||||
apt-get update &>/dev/null
|
||||
echo "OCRLANG variable is set, processing the language packages"
|
||||
for i in ${OCRLANG//,/ }; do
|
||||
if apt-cache show tesseract-ocr-"${i}" > /dev/null 2>&1; then
|
||||
if apt-cache show tesseract-ocr-"${i}" >/dev/null 2>&1; then
|
||||
apt-get install -yq tesseract-ocr-"${i}"
|
||||
bashio::log.info "OCR Language installed : $i" || bashio::log.fatal "Couldn't install OCR lang $i. Please check its format is conform"
|
||||
else
|
||||
|
||||
Reference in New Issue
Block a user