[createrepo/f19] Update to latest HEAD

Zdeněk Pavlas zpavlas at fedoraproject.org
Wed Apr 17 14:58:31 UTC 2013


commit 97bec4022819c04217752c809bdacd3713aa910e
Author: Zdenek Pavlas <zpavlas at redhat.com>
Date:   Wed Apr 17 16:58:04 2013 +0200

    Update to latest HEAD

 createrepo-head.patch |  285 +++++++++++++++++++++++++++++++++++--------------
 createrepo.spec       |   24 ++++-
 2 files changed, 227 insertions(+), 82 deletions(-)
---
diff --git a/createrepo-head.patch b/createrepo-head.patch
index 7ee1dc6..f478085 100644
--- a/createrepo-head.patch
+++ b/createrepo-head.patch
@@ -1,8 +1,46 @@
+diff --git a/Makefile b/Makefile
+index 60bb9db..0b5738b 100644
+--- a/Makefile
++++ b/Makefile
+@@ -1,4 +1,5 @@
+ PKGNAME = createrepo
++ALIASES = mergerepo modifyrepo genpkgmetadata.py mergerepo.py modifyrepo.py
+ VERSION=$(shell awk '/Version:/ { print $$2 }' ${PKGNAME}.spec)
+ RELEASE=$(shell awk '/Release:/ { print $$2 }' ${PKGNAME}.spec)
+ CVSTAG=createrepo-$(subst .,_,$(VERSION)-$(RELEASE))
+@@ -26,6 +27,8 @@ docdir =
+ includedir = ${prefix}/include
+ oldincludedir = /usr/include
+ mandir = ${prefix}/share/man
++compdir = $(shell pkg-config --variable=completionsdir bash-completion)
++compdir := $(or $(compdir), "/etc/bash_completion.d")
+ 
+ pkgdatadir = $(datadir)/$(PKGNAME)
+ pkglibdir = $(libdir)/$(PKGNAME)
+@@ -33,7 +36,7 @@ pkgincludedir = $(includedir)/$(PKGNAME)
+ top_builddir = 
+ 
+ # all dirs
+-DIRS = $(DESTDIR)$(bindir) $(DESTDIR)$(sysconfdir)/bash_completion.d \
++DIRS = $(DESTDIR)$(bindir) $(DESTDIR)$(compdir) \
+ 	$(DESTDIR)$(pkgdatadir) $(DESTDIR)$(mandir)
+ 
+ 
+@@ -65,7 +68,8 @@ check:
+ 
+ install: all installdirs
+ 	$(INSTALL_MODULES) $(srcdir)/$(MODULES) $(DESTDIR)$(pkgdatadir)
+-	$(INSTALL_DATA) $(PKGNAME).bash $(DESTDIR)$(sysconfdir)/bash_completion.d
++	$(INSTALL_DATA) $(PKGNAME).bash $(DESTDIR)$(compdir)/$(PKGNAME)
++	(cd $(DESTDIR)$(compdir); for n in $(ALIASES); do ln -s $(PKGNAME) $$n; done)
+ 	for subdir in $(SUBDIRS) ; do \
+ 	  $(MAKE) -C $$subdir install VERSION=$(VERSION) PKGNAME=$(PKGNAME); \
+ 	done
 diff --git a/createrepo.bash b/createrepo.bash
-index 54ac8b2..f5a8bb7 100644
+index 54ac8b2..14b43d8 100644
 --- a/createrepo.bash
 +++ b/createrepo.bash
-@@ -1,11 +1,17 @@
+@@ -1,11 +1,22 @@
  # bash completion for createrepo and friends
  
 +_cr_compress_type()
@@ -11,6 +49,11 @@ index 54ac8b2..f5a8bb7 100644
 +        | sed -ne 's/,/ /g' -ne 's/.*[Cc]ompression.*://p' )" -- "$2" ) )
 +}
 +
++_cr_checksum_type()
++{
++    COMPREPLY=( $( compgen -W 'md5 sha1 sha256 sha512' -- "$1" ) )
++}
++
  _cr_createrepo()
  {
      COMPREPLY=()
@@ -21,7 +64,18 @@ index 54ac8b2..f5a8bb7 100644
          --revision|-x|--excludes|--changelog-limit|--max-delta-rpm-size)
              return 0
              ;;
-@@ -30,10 +36,24 @@ _cr_createrepo()
+@@ -18,8 +29,8 @@ _cr_createrepo()
+             COMPREPLY=( $( compgen -f -o plusdirs -X '!*.xml' -- "$2" ) )
+             return 0
+             ;;
+-        -s|--sumtype)
+-            COMPREPLY=( $( compgen -W 'md5 sha1 sha256 sha512' -- "$2" ) )
++        -s|--checksum)
++            _cr_checksum_type "$2"
+             return 0
+             ;;
+         -i|--pkglist|--read-pkgs-list)
+@@ -30,10 +41,24 @@ _cr_createrepo()
              COMPREPLY=( $( compgen -f -o plusdirs -X '!*.rpm' -- "$2" ) )
              return 0
              ;;
@@ -46,7 +100,7 @@ index 54ac8b2..f5a8bb7 100644
      esac
  
      if [[ $2 == -* ]] ; then
-@@ -42,9 +62,9 @@ _cr_createrepo()
+@@ -42,9 +67,9 @@ _cr_createrepo()
              --cachedir --checkts --no-database --update --update-md-path
              --skip-stat --split --pkglist --includepkg --outputdir
              --skip-symlinks --changelog-limit --unique-md-filenames
@@ -59,7 +113,7 @@ index 54ac8b2..f5a8bb7 100644
      else
          COMPREPLY=( $( compgen -d -- "$2" ) )
      fi
-@@ -63,10 +83,14 @@ _cr_mergerepo()
+@@ -63,10 +88,14 @@ _cr_mergerepo()
              COMPREPLY=( $( compgen -d -- "$2" ) )
              return 0
              ;;
@@ -75,7 +129,7 @@ index 54ac8b2..f5a8bb7 100644
  } &&
  complete -F _cr_mergerepo -o filenames mergerepo mergerepo.py
  
-@@ -78,17 +102,22 @@ _cr_modifyrepo()
+@@ -78,17 +107,27 @@ _cr_modifyrepo()
          --version|-h|--help|--mdtype)
              return 0
              ;;
@@ -83,12 +137,17 @@ index 54ac8b2..f5a8bb7 100644
 +            _cr_compress_type "" "$2"
 +            return 0
 +            ;;
++        -s|--checksum)
++            _cr_checksum_type "$2"
++            return 0
++            ;;
      esac
  
      if [[ $2 == -* ]] ; then
 -        COMPREPLY=( $( compgen -W '--version --help --mdtype' -- "$2" ) )
 +        COMPREPLY=( $( compgen -W '--version --help --mdtype --remove
-+            --compress --compress-type' -- "$2" ) )
++            --compress --no-compress --compress-type --checksum
++            --unique-md-filenames --simple-md-filenames' -- "$2" ) )
          return 0
      fi
  
@@ -101,10 +160,28 @@ index 54ac8b2..f5a8bb7 100644
          fi
      done
 diff --git a/createrepo.spec b/createrepo.spec
-index 1e491cd..eea7092 100644
+index 1e491cd..9a2179b 100644
 --- a/createrepo.spec
 +++ b/createrepo.spec
-@@ -11,7 +11,7 @@ URL: http://createrepo.baseurl.org/
+@@ -1,5 +1,17 @@
+ %{!?python_sitelib: %define python_sitelib %(python -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")}
+ 
++%if ! 0%{?rhel}
++# we don't have this in rhel yet...
++BuildRequires: bash-completion
++%endif
++
++# disable broken /usr/lib/rpm/brp-python-bytecompile
++%define __os_install_post %{nil}
++%define compdir %(pkg-config --variable=completionsdir bash-completion)
++%if "%{compdir}" == ""
++%define compdir "/etc/bash_completion.d"
++%endif
++
+ Summary: Creates a common metadata repository
+ Name: createrepo
+ Version: 0.9.9
+@@ -11,7 +23,7 @@ URL: http://createrepo.baseurl.org/
  BuildRoot: %{_tmppath}/%{name}-%{version}root
  BuildArchitectures: noarch
  Requires: python >= 2.1, rpm-python, rpm >= 0:4.1.1, libxml2-python
@@ -113,7 +190,16 @@ index 1e491cd..eea7092 100644
  
  %description
  This utility will generate a common metadata repository from a directory of
-@@ -43,6 +43,9 @@ make DESTDIR=$RPM_BUILD_ROOT sysconfdir=%{_sysconfdir} install
+@@ -32,7 +44,7 @@ make DESTDIR=$RPM_BUILD_ROOT sysconfdir=%{_sysconfdir} install
+ %defattr(-, root, root)
+ %dir %{_datadir}/%{name}
+ %doc ChangeLog README COPYING COPYING.lib
+-%{_sysconfdir}/bash_completion.d/
++%(dirname %{compdir})
+ %{_datadir}/%{name}/*
+ %{_bindir}/%{name}
+ %{_bindir}/modifyrepo
+@@ -43,6 +55,9 @@ make DESTDIR=$RPM_BUILD_ROOT sysconfdir=%{_sysconfdir} install
  %{python_sitelib}/createrepo
  
  %changelog
@@ -1352,10 +1438,28 @@ index ac06196..f87ac6d 100644
              except:
                  pass
 diff --git a/docs/createrepo.8 b/docs/createrepo.8
-index e3c4c3b..ff359de 100644
+index e3c4c3b..eefd4bf 100644
 --- a/docs/createrepo.8
 +++ b/docs/createrepo.8
-@@ -53,7 +53,8 @@ gullible).
+@@ -37,6 +37,10 @@ cache of checksums of packages in the repository. In consecutive runs of
+ createrepo over the same repository of files that do not have a complete
+ change out of all packages this decreases the processing time dramatically.
+ .br
++.IP "\fB\--basedir\fP"
++Basedir for path to directories in the repodata, default is the current working
++directory.
++.br
+ .IP "\fB\--update\fP"
+ If metadata already exists in the outputdir and an rpm is unchanged
+ (based on file size and mtime) since the metadata was generated, reuse
+@@ -49,11 +53,15 @@ skip the stat() call on a --update, assumes if the filename is the same
+ then the file is still the same (only use this if you're fairly trusting or
+ gullible).
+ .br
++.IP "\fB\--update-md-path\fP"
++Use the existing repodata for --update, from this path.
++.br
+ .IP "\fB\-C --checkts\fP"
  Don't generate repo metadata, if their timestamps are newer than its rpms.
  This option decreases the processing time drastically again, if you happen
  to run it on an unmodified repo, but it is (currently) mutual exclusive
@@ -1365,7 +1469,27 @@ index e3c4c3b..ff359de 100644
  .br
  .IP "\fB\--split\fP"
  Run in split media mode. Rather than pass a single directory, take a set of
-@@ -104,7 +105,16 @@ Tells createrepo to generate deltarpms and the delta metadata
+@@ -61,7 +69,7 @@ directories corresponding to different volumes in a media set.
+ .br
+ .IP "\fB\-p --pretty\fP"
+ Output xml files in pretty format.
+-.IP "\fB\-V --version\fP"
++.IP "\fB\--version\fP"
+ Output version.
+ .IP "\fB\-h --help\fP"
+ Show help menu.
+@@ -89,6 +97,10 @@ Include the file's checksum in the metadata filename, helps HTTP caching (defaul
+ .IP "\fB\--simple-md-filenames\fP"
+ Do not include the file's checksum in the metadata filename.
+ 
++.IP "\fB\--retain-old-md\fP"
++Keep around the latest (by timestamp) N copies of the old repodata (so clients
++with older repomd.xml files can still access it). Default is 0.
++
+ .IP "\fB\--distro\fP"
+ Specify distro tags. Can be specified more than once. Optional syntax specifying a
+ cpeid(http://cpe.mitre.org/) --distro=cpeid,distrotag
+@@ -104,7 +116,16 @@ Tells createrepo to generate deltarpms and the delta metadata
  paths to look for older pkgs to delta against. Can be specified multiple times
  .IP "\fB\--num-deltas\fP int"
  the number of older versions to make deltas against. Defaults to 1
@@ -1384,9 +1508,18 @@ index e3c4c3b..ff359de 100644
  .SH "EXAMPLES"
  Here is an example of a repository with a groups file. Note that the
 diff --git a/genpkgmetadata.py b/genpkgmetadata.py
-index 8c98191..c46e441 100755
+index 8c98191..4528bf2 100755
 --- a/genpkgmetadata.py
 +++ b/genpkgmetadata.py
+@@ -22,7 +22,7 @@
+ import os
+ import sys
+ import re
+-from optparse import OptionParser
++from optparse import OptionParser,SUPPRESS_HELP
+ import time
+ 
+ import createrepo
 @@ -37,6 +37,12 @@ def parse_args(args, conf):
         Sanity check all the things being passed in.
      """
@@ -1400,10 +1533,19 @@ index 8c98191..c46e441 100755
      _def   = yum.misc._default_checksums[0]
      _avail = yum.misc._available_checksums
      parser = OptionParser(version = "createrepo %s" % createrepo.__version__)
-@@ -100,6 +106,8 @@ def parse_args(args, conf):
-     parser.add_option("--simple-md-filenames", dest="simple_md_filenames",
-         help="do not include the file's checksum in the filename, helps with proxies",
-         default=False, action="store_true")
+@@ -95,11 +101,13 @@ def parse_args(args, conf):
+     parser.add_option("--changelog-limit", dest="changelog_limit",
+         default=None, help="only import the last N changelog entries")
+     parser.add_option("--unique-md-filenames", dest="unique_md_filenames",
+-        help="include the file's checksum in the filename, helps with proxies",
++        help="include the file's checksum in the filename, helps with proxies (default)",
+         default=True, action="store_true")
+-    parser.add_option("--simple-md-filenames", dest="simple_md_filenames",
+-        help="do not include the file's checksum in the filename, helps with proxies",
+-        default=False, action="store_true")
++    parser.add_option("--simple-md-filenames", dest="unique_md_filenames",
++        help="do not include the file's checksum in the filename",
++        action="store_false")
 +    parser.add_option("--retain-old-md", default=0, type='int', dest='retain_old_md',
 +        help="keep around the latest (by timestamp) N copies of the old repodata")
      parser.add_option("--distro", default=[], action="append",
@@ -1420,7 +1562,7 @@ index 8c98191..c46e441 100755
          help="number of workers to spawn to read rpms")
 +    parser.add_option("--xz", default=False,
 +        action="store_true",
-+        help="use xz for repodata compression")
++        help=SUPPRESS_HELP)
 +    parser.add_option("--compress-type", default='compat', dest="compress_type",
 +        help="which compression type to use")
 +        
@@ -1437,8 +1579,13 @@ index 8c98191..c46e441 100755
      if opts.sumtype == 'sha1':
          errorprint(_('Warning: It is more compatible to use sha instead of sha1'))
  
-@@ -155,6 +171,11 @@ def parse_args(args, conf):
-     
+@@ -150,11 +166,13 @@ def parse_args(args, conf):
+         errorprint(_('--split and --checkts options are mutually exclusive'))
+         sys.exit(1)
+ 
+-    if opts.simple_md_filenames:
+-        opts.unique_md_filenames = False
+-    
      if opts.nodatabase:
          opts.database = False
 +    
@@ -1449,7 +1596,7 @@ index 8c98191..c46e441 100755
          
      # let's switch over to using the conf object - put all the opts into it
      for opt in parser.option_list:
-@@ -240,6 +261,7 @@ def main(args):
+@@ -240,6 +258,7 @@ def main(args):
              if mdgen.checkTimeStamps():
                  if mdgen.conf.verbose:
                      print _('repo is up to date')
@@ -1499,7 +1646,7 @@ index 05e5f5e..80cb1a8 100755
  if __name__ == "__main__":
      main(sys.argv[1:])
 diff --git a/modifyrepo.py b/modifyrepo.py
-index 17094a4..acdde77 100755
+index 17094a4..bffe99a 100755
 --- a/modifyrepo.py
 +++ b/modifyrepo.py
 @@ -1,11 +1,15 @@
@@ -1534,16 +1681,16 @@ index 17094a4..acdde77 100755
  from yum.misc import checksum
  
  from yum.repoMDObject import RepoMD, RepoMDError, RepoData
-@@ -39,6 +45,8 @@ class RepoMetadata:
+@@ -38,7 +44,7 @@ class RepoMetadata:
+         """ Parses the repomd.xml file existing in the given repo directory. """
          self.repodir = os.path.abspath(repo)
          self.repomdxml = os.path.join(self.repodir, 'repomd.xml')
-         self.checksum_type = 'sha256'
-+        self.compress = False
+-        self.checksum_type = 'sha256'
 +        self.compress_type = _available_compression[-1] # best available
  
          if not os.path.exists(self.repomdxml):
              raise MDError, '%s not found' % self.repomdxml
-@@ -49,6 +57,35 @@ class RepoMetadata:
+@@ -49,6 +55,35 @@ class RepoMetadata:
          except RepoMDError, e:
              raise MDError, 'Could not parse %s' % self.repomdxml
  
@@ -1579,7 +1726,7 @@ index 17094a4..acdde77 100755
  
      def add(self, metadata, mdtype=None):
          """ Insert arbitrary metadata into this repository.
-@@ -63,8 +100,8 @@ class RepoMetadata:
+@@ -63,8 +98,8 @@ class RepoMetadata:
              mdname = 'updateinfo.xml'
          elif isinstance(metadata, str):
              if os.path.exists(metadata):
@@ -1590,7 +1737,7 @@ index 17094a4..acdde77 100755
                  else:
                      oldmd = file(metadata, 'r')
                  md = oldmd.read()
-@@ -75,14 +112,19 @@ class RepoMetadata:
+@@ -75,27 +110,32 @@ class RepoMetadata:
          else:
              raise MDError, 'invalid metadata type'
  
@@ -1601,7 +1748,7 @@ index 17094a4..acdde77 100755
 -        if not mdtype:
 -            mdtype = mdname.split('.')[0]
 -            
-+        if self.compress or not mdname.split('.')[-1] in ('gz', 'bz2', 'xz'):
++        if self.compress and mdname.split('.')[-1] not in ('gz', 'bz2', 'xz'):
 +            do_compress = True
 +            mdname += '.' + self.compress_type
 +        mdtype = self._get_mdtype(mdname, mdtype)
@@ -1616,8 +1763,13 @@ index 17094a4..acdde77 100755
          newmd.write(md)
          newmd.close()
          print "Wrote:", destmd
-@@ -91,11 +133,8 @@ class RepoMetadata:
-         csum, destmd = checksum_and_rename(destmd, self.checksum_type)
+ 
+         open_csum = checksum(self.checksum_type, metadata)
+-        csum, destmd = checksum_and_rename(destmd, self.checksum_type)
++        if self.unique_md_filenames:
++            csum, destmd = checksum_and_rename(destmd, self.checksum_type)
++        else:
++            csum = checksum(self.checksum_type, destmd)
          base_destmd = os.path.basename(destmd)
  
 -
@@ -1630,7 +1782,7 @@ index 17094a4..acdde77 100755
  
          new_rd = RepoData()
          new_rd.type = mdtype
-@@ -103,20 +142,30 @@ class RepoMetadata:
+@@ -103,20 +143,30 @@ class RepoMetadata:
          new_rd.checksum = (self.checksum_type, csum)
          new_rd.openchecksum = (self.checksum_type, open_csum)
          new_rd.size = str(os.stat(destmd).st_size)
@@ -1674,30 +1826,44 @@ index 17094a4..acdde77 100755
  
  
  def main(args):
-@@ -124,7 +173,13 @@ def main(args):
+@@ -124,7 +174,23 @@ def main(args):
      # query options
      parser.add_option("--mdtype", dest='mdtype',
                        help="specific datatype of the metadata, will be derived from the filename if not specified")
 -    parser.usage = "modifyrepo [options] <input_metadata> <output repodata>"
 +    parser.add_option("--remove", action="store_true",
 +                      help="remove specified file from repodata")
-+    parser.add_option("--compress", action="store_true", default=False,
-+                      help="compress the new repodata before adding it to the repo")
++    parser.add_option("--compress", action="store_true", default=True,
++                      help="compress the new repodata before adding it to the repo (default)")
++    parser.add_option("--no-compress", action="store_false", dest="compress",
++                      help="do not compress the new repodata before adding it to the repo")
 +    parser.add_option("--compress-type", dest='compress_type', default='gz',
 +                      help="compression format to use")
++    parser.add_option("-s", "--checksum", default='sha256', dest='sumtype',
++        help="specify the checksum type to use (default: sha256)")
++    parser.add_option("--unique-md-filenames", dest="unique_md_filenames",
++        help="include the file's checksum in the filename, helps with proxies (default)",
++        default=True, action="store_true")
++    parser.add_option("--simple-md-filenames", dest="unique_md_filenames",
++        help="do not include the file's checksum in the filename",
++        action="store_false")
 +    parser.usage = "modifyrepo [options] [--remove] <input_metadata> <output repodata>"
      
      (opts, argsleft) = parser.parse_args(args)
      if len(argsleft) != 2:
-@@ -137,11 +192,28 @@ def main(args):
+@@ -137,11 +203,32 @@ def main(args):
      except MDError, e:
          print "Could not access repository: %s" % str(e)
          return 1
 +
 +
++    repomd.checksum_type = opts.sumtype
++    repomd.unique_md_filenames = opts.unique_md_filenames
 +    repomd.compress = opts.compress
-+    if opts.compress_type in _available_compression:
-+        repomd.compress_type = opts.compress_type
++    if opts.compress_type not in _available_compression:
++        print "Compression %s not available: Please choose from: %s" % (opts.compress_type, ', '.join(_available_compression))
++        return 1
++    repomd.compress_type = opts.compress_type
 +
 +    # remove
 +    if opts.remove:
@@ -1822,44 +1988,3 @@ index eb35ef7..b67b5bd 100755
 -    
  if __name__ == "__main__":
      main(sys.argv[1:])
-commit 24b6f750b382781d5c257e4afdd04f30488d6da5
-Author: Zdenek Pavlas <zpavlas at redhat.com>
-Date:   Tue Mar 19 10:00:01 2013 +0100
-
-    move bash-completion scripts to /usr/share/  BZ 923001
-
-diff --git a/Makefile b/Makefile
-index 60bb9db..d23ad8b 100644
---- a/Makefile
-+++ b/Makefile
-@@ -33,7 +33,7 @@ pkgincludedir = $(includedir)/$(PKGNAME)
- top_builddir = 
- 
- # all dirs
--DIRS = $(DESTDIR)$(bindir) $(DESTDIR)$(sysconfdir)/bash_completion.d \
-+DIRS = $(DESTDIR)$(bindir) $(DESTDIR)$(datadir)/bash-completion/completions \
- 	$(DESTDIR)$(pkgdatadir) $(DESTDIR)$(mandir)
- 
- 
-@@ -65,7 +65,7 @@ check:
- 
- install: all installdirs
- 	$(INSTALL_MODULES) $(srcdir)/$(MODULES) $(DESTDIR)$(pkgdatadir)
--	$(INSTALL_DATA) $(PKGNAME).bash $(DESTDIR)$(sysconfdir)/bash_completion.d
-+	$(INSTALL_DATA) $(PKGNAME).bash $(DESTDIR)$(datadir)/bash-completion/completions/$(PKGNAME)
- 	for subdir in $(SUBDIRS) ; do \
- 	  $(MAKE) -C $$subdir install VERSION=$(VERSION) PKGNAME=$(PKGNAME); \
- 	done
-diff --git a/createrepo.spec b/createrepo.spec
-index eea7092..e94b36b 100644
---- a/createrepo.spec
-+++ b/createrepo.spec
-@@ -32,7 +32,7 @@ make DESTDIR=$RPM_BUILD_ROOT sysconfdir=%{_sysconfdir} install
- %defattr(-, root, root)
- %dir %{_datadir}/%{name}
- %doc ChangeLog README COPYING COPYING.lib
--%{_sysconfdir}/bash_completion.d/
-+%{_datadir}/bash-completion/completions/createrepo
- %{_datadir}/%{name}/*
- %{_bindir}/%{name}
- %{_bindir}/modifyrepo
diff --git a/createrepo.spec b/createrepo.spec
index 5e69e42..7ce684d 100644
--- a/createrepo.spec
+++ b/createrepo.spec
@@ -1,9 +1,21 @@
 %{!?python_sitelib: %define python_sitelib %(python -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")}
 
+%if ! 0%{?rhel}
+# we don't have this in rhel yet...
+BuildRequires: bash-completion
+%endif
+
+# disable broken /usr/lib/rpm/brp-python-bytecompile
+%define __os_install_post %{nil}
+%define compdir %(pkg-config --variable=completionsdir bash-completion)
+%if "%{compdir}" == ""
+%define compdir "/etc/bash_completion.d"
+%endif
+
 Summary: Creates a common metadata repository
 Name: createrepo
 Version: 0.9.9
-Release: 17%{?dist}
+Release: 18%{?dist}
 License: GPLv2
 Group: System Environment/Base
 Source: %{name}-%{version}.tar.gz
@@ -38,7 +50,7 @@ rm -rf $RPM_BUILD_ROOT
 %files
 %defattr(-, root, root,-)
 %doc ChangeLog README COPYING COPYING.lib
-%{_datadir}/bash-completion/completions/createrepo
+%(dirname %{compdir})
 %{_datadir}/%{name}/
 %{_bindir}/createrepo
 %{_bindir}/modifyrepo
@@ -47,6 +59,14 @@ rm -rf $RPM_BUILD_ROOT
 %{python_sitelib}/createrepo
 
 %changelog
+* Wed Apr 17 2013 Zdenek Pavlas <zpavlas at redhat.com> - 0.9.9-18
+- update to latest HEAD
+- don't BuildRequire bash-completion in rhel
+- Fail for bad compress-type options to modifyrepo, like createrepo. BZ 886589
+- Fix options documentation. BZ 892657.
+- modifyrepo: fix --compress option bug. BZ 950724
+- modifyrepo: add --checksum and --{unique,simple}-md-filenames options
+
 * Tue Mar 19 2013 Zdenek Pavlas <zpavlas at redhat.com> - 0.9.9-17
 - move bash-completion scripts to /usr/share/  BZ 923001
 


More information about the scm-commits mailing list