summaryrefslogtreecommitdiffstats
path: root/mkrepo
diff options
context:
space:
mode:
authorRemi Collet <fedora@famillecollet.com>2017-03-06 12:05:08 +0100
committerRemi Collet <fedora@famillecollet.com>2017-03-06 12:05:08 +0100
commitb9a4941731cdeb708835aabe4eb2b91bc287f74b (patch)
tree4e7ad93459ed789291c0d717e3db1ff422dbcc97 /mkrepo
parent8eda7d954b6949b9b0f80db10b7a31a6b82324b2 (diff)
open Fedora 26 repository with a fresh new GPG key
Diffstat (limited to 'mkrepo')
-rwxr-xr-xmkrepo24
1 files changed, 14 insertions, 10 deletions
diff --git a/mkrepo b/mkrepo
index de68f58..1ef3e20 100755
--- a/mkrepo
+++ b/mkrepo
@@ -2,20 +2,11 @@
#set -x
TMP=/tmp/liste.$(basename $PWD)
-if [ ${1:-check} != nocheck ]; then
- echo "+ Controle des signatures"
- rpm -K *.rpm | grep -v 'gpg OK' | cut -d: -f1 | tee $TMP
- if [ -s $TMP ]
- then rpmsign --addsign $(cat $TMP)
- else echo OK.
- fi
-fi
-
nom=${PWD#/home/rpmbuild/site/rpms/}
if [ "$nom" = "SRPMS" ]
then
dis=fedora
- ver=17
+ ver=26
old=5
else
dis=${nom%%/*}
@@ -24,6 +15,19 @@ else
old=2
fi
+if [ ${1:-check} != nocheck ]; then
+ echo "+ Controle des signatures"
+ rpm -K *.rpm | grep -v 'gpg OK' | cut -d: -f1 | tee $TMP
+ if [ -s $TMP ]
+ then
+ if [ $dis == fedora -a $ver -ge 26 ]
+ then rpmsign --define '_gpg_path /home/remi/.gnupg2017' --define "_gpg_name Remi's RPM repository" --addsign $(cat $TMP)
+ else rpmsign --define '_gpg_path /home/remi/.gnupgrpm' --define "_gpg_name Remi Collet" --addsign $(cat $TMP)
+ fi
+ else echo OK.
+ fi
+fi
+
echo "+ Nettoyage des anciens ($old)"
dnf repomanage --old --keep=$old . | tee $TMP