A live bird collage card for your Home Assistant dashboard.
Update update_birdnet.sh
Patrick McGuired3d1dbcd07cf
diff --git a/scripts/update_birdnet.sh b/scripts/update_birdnet.shindex 50e74bfe..0b82e319 100755--- a/scripts/update_birdnet.sh+++ b/scripts/update_birdnet.sh@@ -5,6 +5,10 @@ trap 'exit 1' SIGINT SIGHUPusage() { echo "Usage: $0 [-r <remote name>] [-b <branch name>]" 1>&2; exit 1; }+USER=$(awk -F: '/1000/ {print $1}' /etc/passwd)+HOME=$(awk -F: '/1000/ {print $6}' /etc/passwd)+my_dir=$HOME/BirdNET-Pi/scripts+# Defaultsremote="origin"branch="main"@@ -31,11 +35,6 @@ while getopts ":r:b:" o; dodoneshift $((OPTIND-1))-USER=$(awk -F: '/1000/ {print $1}' /etc/passwd)-HOME=$(awk -F: '/1000/ {print $6}' /etc/passwd)-my_dir=$HOME/BirdNET-Pi/scripts--sudo_with_user () {set -xsudo -u $USER "$@"