This commit is contained in:
Alexandre
2024-10-12 10:20:37 +02:00
committed by GitHub
parent 3618aa5819
commit 9b7ebe468d

View File

@@ -54,7 +54,10 @@ chown -R pi:pi /config /etc/birdnet "$BIRDSONGS_FOLDER" /tmp
chmod -R 755 /config /etc/birdnet "$BIRDSONGS_FOLDER" /tmp
# Create default birds.db
if [ ! -f "$HOME/BirdNET-Pi/scripts/birds.db" ]; then
if [ $(stat -c%s "$HOME/BirdNET-Pi/birds.db") -lt 10240 ]; then
rm "$HOME/BirdNET-Pi/birds.db"
fi
if [ ! -f "$HOME/BirdNET-Pi/birds.db" ]; then
"$HOME/BirdNET-Pi/scripts/createdb.sh"
fi