searxng/diff.sh

14 lines
391 B
Bash
Raw Normal View History

2024-05-01 08:36:34 +00:00
#!/bin/bash -e
. ./.env
DOCKER_API='https://hub.docker.com/v2/namespaces/searxng/repositories/searxng'
REPO='https://github.com/searxng/searxng/raw'
new_tag="$(curl -L "$DOCKER_API/tags" | jq -r '.results[3].name')"
new_commit="$(grep -Eo '\w+$' <<< "$new_tag")"
$EDITOR -d -c "wincmd l" -- "$REPO/$new_commit/searx/settings.yml" settings.yml
sed -i "/^IMAGEAPP=/s/:.*/:$new_tag/" .env