#!/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