Skip to content

Instantly share code, notes, and snippets.

@dafyddcrosby
Created April 26, 2013 03:59
Show Gist options
  • Save dafyddcrosby/5464967 to your computer and use it in GitHub Desktop.
Save dafyddcrosby/5464967 to your computer and use it in GitHub Desktop.
#!/bin/sh
REPODIR=~/repo/rhel/
SRPMS=$REPODIR/SRPMS
RELEASES=6
ARCHS=x86_64
CREATEREPO="createrepo -d --update"
# Sign all packages
#PACKAGES=`find $REPODIR -name \*.rpm -printf '%p '`
#echo $PACKAGES
#rpm --resign $PACKAGES
#rpm --resign `find $REPODIR -name \*.rpm -printf '%p '`
# Make repodata
for release in $RELEASES
do
$CREATEREPO --update $REPODIR/$release/SRPMS/
for arch in $ARCHS
do
$CREATEREPO --update $REPODIR/$release/$arch/
$CREATEREPO --update $REPODIR/$release/$arch/debug/
done
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment