mirror of
https://github.com/alexbelgium/hassio-addons.git
synced 2026-06-12 10:31:26 +02:00
Update 99-run.sh
This commit is contained in:
@@ -25,14 +25,14 @@ if [ -f $CONFIGSOURCE ]; then
|
|||||||
bashio::log.info "Using config file found in $CONFIGSOURCE"
|
bashio::log.info "Using config file found in $CONFIGSOURCE"
|
||||||
|
|
||||||
# Check if yaml is valid
|
# Check if yaml is valid
|
||||||
yamllint -d relaxed --no-warnings $CONFIGSOURCE &> ERROR || EXIT_CODE=$?
|
# yamllint -d relaxed --no-warnings $CONFIGSOURCE &> ERROR || EXIT_CODE=$?
|
||||||
if [ $EXIT_CODE = 0 ]; then
|
# if [ $EXIT_CODE = 0 ]; then
|
||||||
echo "Config file is a valid yaml"
|
# echo "Config file is a valid yaml"
|
||||||
else
|
# else
|
||||||
cat ERROR
|
# cat ERROR
|
||||||
bashio::log.fatal "Config file has an invalid yaml format. Please check the file in $CONFIGSOURCE. Errors list above."
|
# bashio::log.fatal "Config file has an invalid yaml format. Please check the file in $CONFIGSOURCE. Errors list above."
|
||||||
bashio::exit.nok
|
# bashio::exit.nok
|
||||||
fi
|
# fi
|
||||||
else
|
else
|
||||||
# Create symlink for addon to create config
|
# Create symlink for addon to create config
|
||||||
touch ${CONFIGSOURCE}
|
touch ${CONFIGSOURCE}
|
||||||
|
|||||||
Reference in New Issue
Block a user