[projects/pld-ftp-admin] pfa-genindex: drop rpmrepo support

arekm arekm at pld-linux.org
Tue Oct 20 13:17:17 CEST 2026


commit 3d34af9a231c5fa5a5cbf39cda1ed0b6ac170f6f
Author: Arkadiusz Miśkiewicz <arekm at maven.pl>
Date:   Tue Oct 20 12:44:47 2026 +0200

    pfa-genindex: drop rpmrepo support
    
    rpmrepo is an rpm5 tool and does not exist in rpm.org.

 bin/pfa-genindex         | 33 ++++++---------------------------
 shell/bash-completion.sh |  4 ++--
 2 files changed, 8 insertions(+), 29 deletions(-)
---
diff --git a/bin/pfa-genindex b/bin/pfa-genindex
index acaaabb..58d85f8 100755
--- a/bin/pfa-genindex
+++ b/bin/pfa-genindex
@@ -15,18 +15,17 @@ try:
     opts, args = getopt.getopt(sys.argv[1:], 'q',
         [
             "quiet", "index=",
-            "nopoldek", "noyum", "norpmrepo",
-            "poldek", "yum", "rpmrepo"
+            "nopoldek", "noyum",
+            "poldek", "yum"
         ]
     )
 except getopt.GetoptError:
     print("ERR: not enough parameters given", file=sys.stderr)
-    print("gen-indexes.py [--quiet] [--[no]poldek] [--[no]yum] [--[no]rpmrepo] tree [tree2...]", file=sys.stderr)
+    print("pfa-genindex [--quiet] [--[no]poldek] [--[no]yum] tree [tree2...]", file=sys.stderr)
     sys.exit(1)
 
 do_poldek = True
 do_yum = True
-do_rpmrepo = False
 quiet = False
 # update only if changed (applicable to yum)
 freshen = True
@@ -36,33 +35,27 @@ for o, a in opts:
         do_poldek = False
     if o == "--noyum":
         do_yum = False
-    if o == "--norpmrepo":
-        do_rpmrepo = False
 
     if o == "--poldek":
         do_poldek = True
     if o == "--yum":
         do_yum = True
-    if o == "--rpmrepo":
-        do_rpmrepo = True
 
     if o == "-q" or o == "--quiet":
         quiet = True
 
     if o == "--index":
-        do_poldek = do_yum = do_rpmrepo = False
+        do_poldek = do_yum = False
         for v in a.split(','):
             if v == 'poldek':
                 do_poldek = True
             if v == 'yum':
                 do_yum = True
-            if v == 'rpmrepo':
-                do_rpmrepo = True
 
 if not quiet:
-    print("poldek: %s; yum: %s; rpmrepo: %s" % (do_poldek, do_yum, do_rpmrepo))
+    print("poldek: %s; yum: %s" % (do_poldek, do_yum))
 
-if not do_poldek and not do_yum and not do_rpmrepo:
+if not do_poldek and not do_yum:
     print("ERR: speciy at least one action", file=sys.stderr)
     sys.exit(1)
 
@@ -127,19 +120,5 @@ if do_yum:
             if arch != 'noarch' and config.separate_debuginfo:
                 os.system('%s %s --cachedir=%s-%s %s/debuginfo' % ("" if quiet else "time", yum, cachedir, arch, archdir))
 
-if do_rpmrepo:
-    os.system('%s cd %s.stat/repodata && cvs %s up comps.xml' % ("" if quiet else "set -x;", ftp_dir, "" if quiet else "-Q"))
-    for tree in trees:
-        print('\n-------------------------- %s --------------------------' % tree)
-        for arch in all_ftp_archs:
-            dir = '%s/%s/%s/RPMS' % (ftp_dir, tree, arch)
-            if not quiet:
-                print('\ngenerate repodata for %s using rpmrepo (in %s)' % (arch, dir))
-            os.system('%s rpmrepo %s -o %s' % ("" if quiet else "set -x;", dir, dir))
-            if not quiet:
-                print('copy comps.xml')
-            comps = '%s.stat/repodata/comps.xml' % ftp_dir
-            os.system('%s cp -p %s %s/repodata' % ("" if quiet else "set -x;", comps, dir))
-
 for tree in trees:
     ftpio.unlock(tree)
diff --git a/shell/bash-completion.sh b/shell/bash-completion.sh
index ca05c32..49bb7fa 100644
--- a/shell/bash-completion.sh
+++ b/shell/bash-completion.sh
@@ -44,8 +44,8 @@ _pfa-genindex()
     if [[ "$cur" == -* ]]; then
         COMPREPLY=( $( compgen -W '\
             -q --quiet --index \
-            --nopoldek --noyum --norpmrepo \
-            --poldek --yum --rpmrepo \
+            --nopoldek --noyum \
+            --poldek --yum \
             ' \
             -- "$cur" ) )
     else
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/projects/pld-ftp-admin.git/commitdiff/0e823b7af918fae7f654eb4f72e63d95a1af8cdb



More information about the pld-cvs-commit mailing list