projects
/
git-tools-moved-to-github.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
5e61b26
)
Rebuild repo only for non-empty dirs (once)
author
Jakub Skoczen
<jakub@indexdata.dk>
Mon, 12 Jul 2010 14:00:15 +0000
(16:00 +0200)
committer
Jakub Skoczen
<jakub@indexdata.dk>
Mon, 12 Jul 2010 14:00:15 +0000
(16:00 +0200)
update-archive/update-yum-archve.sh
patch
|
blob
|
history
diff --git
a/update-archive/update-yum-archve.sh
b/update-archive/update-yum-archve.sh
index
54b208a
..
9d49d26
100755
(executable)
--- a/
update-archive/update-yum-archve.sh
+++ b/
update-archive/update-yum-archve.sh
@@
-48,6
+48,7
@@
for vdist in centos/5.5 rhel/5.5; do
fi
done
for arch in $architectures; do
fi
done
for arch in $architectures; do
+ dirs_to_upd="${dirs_to_upd} ${ftpdir}/${d}/${arch}"
for l in $d/$arch/Packages/*; do
if test -L "$l"; then
if test ! -f "$l"; then
for l in $d/$arch/Packages/*; do
if test -L "$l"; then
if test ! -f "$l"; then
@@
-85,7
+86,6
@@
for vdist in centos/5.5 rhel/5.5; do
has_packages=true
fi
done
has_packages=true
fi
done
- dirs_to_upd="${dirs_to_upd} ${ftpdir}/${d}/${arch}"
done
fi
fi
done
fi
fi
@@
-97,17
+97,20
@@
rpm --addsign ${pkgs_to_sign}
chgrp staff ${pkgs_to_sign}
chmod g+w ${pkgs_to_sign}
echo "Updating repository meta:"
chgrp staff ${pkgs_to_sign}
chmod g+w ${pkgs_to_sign}
echo "Updating repository meta:"
-echo ${dirs_to_upd}
for rdir in ${dirs_to_upd}; do
for rdir in ${dirs_to_upd}; do
- createrepo --update ${rdir}
- if test -f ${rdir}/repodata/repomd.xml.asc; then
- rm ${rdir}/repodata/repomd.xml.asc
+ echo "Section ${rdir}"
+ if test -d $rdir && ls -A $rdir; then
+ createrepo --update ${rdir}
+ if test -f ${rdir}/repodata/repomd.xml.asc; then
+ rm ${rdir}/repodata/repomd.xml.asc
+ fi
+ gpg --detach-sign -u "Index Data" --armor ${rdir}/repodata/repomd.xml
+ else
+ echo "Empty."
fi
fi
- gpg --detach-sign -u "Index Data" --armor ${rdir}/repodata/repomd.xml
done
# Local Variables:
# mode:shell-script
# sh-indentation: 2
# sh-basic-offset: 8
# End:
done
# Local Variables:
# mode:shell-script
# sh-indentation: 2
# sh-basic-offset: 8
# End:
-