mirror of
https://github.com/esphome/esphome.git
synced 2024-11-10 09:17:46 +01:00
Tidy HA addon (#1937)
This commit is contained in:
parent
fe7af21c91
commit
b3ae3e1feb
2 changed files with 0 additions and 34 deletions
|
@ -1,23 +0,0 @@
|
||||||
#!/usr/bin/with-contenv bashio
|
|
||||||
# ==============================================================================
|
|
||||||
# Community Hass.io Add-ons: ESPHome
|
|
||||||
# This files installs the user ESPHome version if specified
|
|
||||||
# ==============================================================================
|
|
||||||
|
|
||||||
declare esphome_version
|
|
||||||
|
|
||||||
if bashio::config.has_value 'esphome_version'; then
|
|
||||||
esphome_version=$(bashio::config 'esphome_version')
|
|
||||||
if [[ $esphome_version == *":"* ]]; then
|
|
||||||
IFS=':' read -r -a array <<< "$esphome_version"
|
|
||||||
username=${array[0]}
|
|
||||||
ref=${array[1]}
|
|
||||||
else
|
|
||||||
username="esphome"
|
|
||||||
ref=$esphome_version
|
|
||||||
fi
|
|
||||||
full_url="https://github.com/${username}/esphome/archive/${ref}.zip"
|
|
||||||
bashio::log.info "Installing esphome version '${esphome_version}' (${full_url})..."
|
|
||||||
pip3 install -U --no-cache-dir "${full_url}" \
|
|
||||||
|| bashio::exit.nok "Failed installing esphome pinned version."
|
|
||||||
fi
|
|
|
@ -1,11 +0,0 @@
|
||||||
#!/usr/bin/with-contenv bashio
|
|
||||||
# ==============================================================================
|
|
||||||
# Community Hass.io Add-ons: ESPHome
|
|
||||||
# This files migrates the esphome config directory from the old path
|
|
||||||
# ==============================================================================
|
|
||||||
|
|
||||||
if [[ ! -d /config/esphome && -d /config/esphomeyaml ]]; then
|
|
||||||
echo "Moving config directory from /config/esphomeyaml to /config/esphome"
|
|
||||||
mv /config/esphomeyaml /config/esphome
|
|
||||||
mv /config/esphome/.esphomeyaml /config/esphome/.esphome
|
|
||||||
fi
|
|
Loading…
Reference in a new issue