2 commits - createrepo.bash
[email protected] (Ville Skytt??) Fri, 5 Apr 2013 15:26:56 +0000 (UTC)
| Newsgroups | gmane.linux.rpm.metadata |
|---|---|
| Message-ID | <[email protected]> |
--===============0545545140120388794== Content-Type: text/plain createrepo.bash | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) New commits: commit 9b75c361142758989f069ae230583ad63755c34c Author: Ville Skyttä <[email protected]> Date: Fri Apr 5 18:25:39 2013 +0300 modifyrepo: Add --checksum and --{unique,simple}-md-filenames to completions. diff --git a/createrepo.bash b/createrepo.bash index 8cef728..4b2cc36 100644 --- a/createrepo.bash +++ b/createrepo.bash @@ -6,6 +6,11 @@ _cr_compress_type() | sed -ne 's/,/ /g' -ne 's/.*[Cc]ompression.*://p' )" -- "$2" ) ) } +_cr_checksum_type() +{ + COMPREPLY=( $( compgen -W 'md5 sha1 sha256 sha512' -- "$1" ) ) +} + _cr_createrepo() { COMPREPLY=() @@ -25,7 +30,7 @@ _cr_createrepo() return 0 ;; -s|--checksum) - COMPREPLY=( $( compgen -W 'md5 sha1 sha256 sha512' -- "$2" ) ) + _cr_checksum_type "$2" return 0 ;; -i|--pkglist|--read-pkgs-list) @@ -106,11 +111,16 @@ _cr_modifyrepo() _cr_compress_type "" "$2" return 0 ;; + -s|--checksum) + _cr_checksum_type "$2" + return 0 + ;; esac if [[ $2 == -* ]] ; then COMPREPLY=( $( compgen -W '--version --help --mdtype --remove - --compress --compress-type' -- "$2" ) ) + --compress --compress-type --checksum --unique-md-filenames + --simple-md-filenames' -- "$2" ) ) return 0 fi commit e9407244f389d227744c13e30392d676fccfbcbc Author: Ville Skyttä <[email protected]> Date: Fri Apr 5 18:24:03 2013 +0300 createrepo: Fix --checksum arg completion. diff --git a/createrepo.bash b/createrepo.bash index f5a8bb7..8cef728 100644 --- a/createrepo.bash +++ b/createrepo.bash @@ -24,7 +24,7 @@ _cr_createrepo() COMPREPLY=( $( compgen -f -o plusdirs -X '!*.xml' -- "$2" ) ) return 0 ;; - -s|--sumtype) + -s|--checksum) COMPREPLY=( $( compgen -W 'md5 sha1 sha256 sha512' -- "$2" ) ) return 0 ;; --===============0545545140120388794== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Rpm-metadata mailing list [email protected] http://lists.baseurl.org/mailman/listinfo/rpm-metadata --===============0545545140120388794==--