mirror of
https://github.com/basnijholt/adaptive-lighting.git
synced 2026-09-11 22:34:04 +02:00
20 lines
582 B
Bash
Executable file
20 lines
582 B
Bash
Executable file
#!/usr/bin/env bash
|
|
|
|
set -ex
|
|
|
|
cd "$(dirname "$0")/.."
|
|
|
|
# Create config dir if not present
|
|
if [[ ! -d "${PWD}/config" ]]; then
|
|
mkdir -p "${PWD}/config"
|
|
hass --config "${PWD}/config" --script ensure_config
|
|
fi
|
|
|
|
# Set the path to custom_components
|
|
## This let's us have the structure we want <root>/custom_components/adaptive_lighting
|
|
## while at the same time have Home Assistant configuration inside <root>/config
|
|
## without resulting to symlinks.
|
|
export PYTHONPATH="${PYTHONPATH}:${PWD}/custom_components"
|
|
|
|
# Start Home Assistant
|
|
uv run hass --config "${PWD}/config" --debug
|