mirror of
https://github.com/xlionjuan/searxng-mcp-go.git
synced 2026-11-17 04:17:51 +00:00
30 lines
769 B
Shell
Executable file
30 lines
769 B
Shell
Executable file
#!/usr/bin/env bash
|
|
set -euo pipefail
|
|
|
|
cd "$(dirname "$0")"
|
|
|
|
# Check uvx availability (uvx is part of uv, but verify uvx command is on PATH)
|
|
if ! command -v uvx &>/dev/null; then
|
|
echo "Error: uvx not found. Install uv: curl -LsSf https://astral.sh/uv/install.sh | sh" >&2
|
|
exit 1
|
|
fi
|
|
|
|
echo "--- Clearing existing dependencies from pyproject.toml ---"
|
|
|
|
uvx --from tomlkit python - <<'PY'
|
|
from pathlib import Path
|
|
import tomlkit
|
|
|
|
path = Path("pyproject.toml")
|
|
doc = tomlkit.parse(path.read_text())
|
|
|
|
doc["project"]["dependencies"] = tomlkit.array()
|
|
doc["project"]["dependencies"].multiline(True)
|
|
|
|
path.write_text(tomlkit.dumps(doc))
|
|
PY
|
|
|
|
# Import deps from SearXNG
|
|
uv add setuptools ruamel.yaml -r searxng/requirements.txt -r searxng/requirements-server.txt
|
|
|
|
uv lock
|