From f019f312cdc76ddd58cb7b3f58fee1831b8b9335 Mon Sep 17 00:00:00 2001 From: Silvan Calarco Date: Sat, 6 Jul 2024 22:20:17 +0200 Subject: [PATCH] distroquery.php: support for multiarch packages in repository packages list table --- distroquery.php | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/distroquery.php b/distroquery.php index 3fdc232..9722f25 100644 --- a/distroquery.php +++ b/distroquery.php @@ -64,7 +64,7 @@ $url_prefix = home_url() . "/rpms/"; $j = json_decode($request["body"], true); if ($j["error"] != "") { - echo "

ERROR: " . $j["error"] . "

"; + echo "
ERROR: " . $j["error"] . "
"; } else { echo " > " . $repo; @@ -114,11 +114,18 @@ $url_prefix = home_url() . "/rpms/"; echo "0 " . _r("result(s) found"); } - echo ""; + echo "
" . _r("Name") . "" . _r("Version") . "" . - _r("Summary") . "" . _r("Last update") . "
"; foreach ($j["packages"] as $package) { $package_url = $url_prefix . $repo . "/" . $package["name"]; - echo ""; }
" . + _r("Arch") . "" . + _r("Name") . "" . + _r("Version") . "" . + _r("Summary") . "" . + _r("Last update") . "
". $package["name"] . "" . + if ($package["arch"] != "src") $package_url .= "/" . $package["arch"]; + echo "
" . + $package["arch"] . "" . + "". $package["name"] . "" . $package["version"] . "-" . $package["release"] . "" . $package["summary"] . "" . substr($package["buildtime"], 0, 10) . "