update update_clamav.sh

This commit is contained in:
Sérgio M. Basto 2023-09-01 15:42:53 +01:00
parent bf3e645305
commit 93828a0ff0
1 changed files with 7 additions and 5 deletions

View File

@ -14,8 +14,8 @@ TARBALL=${NAME}-${VERSION}.tar.gz
echo "Usage: $0 stage"
echo "stage 0: prepare sources"
echo "stage 1: get cvd (not working at all) the donwload needs to be done manually"
echo "stage 2: upload sources and ask for scratch build"
echo "stage 1: get cvd using cvdupdate https://pypi.org/project/cvdupdate/"
echo "stage 2: ask for scratch build and upload sources"
echo "stage 3: push and build on rawhide"
echo "stage 4: build on others branches"
echo ""
@ -23,12 +23,15 @@ echo ""
if test $stage -le 0
then
echo STAGE 0
echo Press enter to prepare sources or n to skip ; read dummy;
echo Press enter to prepare sources and bump version or n to skip ; read dummy;
if [[ "$dummy" != "n" ]]; then
wget -c https://www.clamav.net/downloads/production/${TARBALL}
wget -c https://www.clamav.net/downloads/production/${TARBALL}.sig
gpg --verify ${TARBALL}.sig ${TARBALL}
zcat ${TARBALL} | tar --delete -f - '*/libclamunrar/*' | xz -c > ${TARBALL_CLEAN}
git checkout rawhide
git pull
rpmdev-bumpspec -n $VERSION -c "Update to $VERSION" clamav.spec
fi
fi
@ -64,8 +67,6 @@ fi
if test $stage -le 2
then
echo STAGE 2
rpmdev-bumpspec -n $VERSION -c "Update to $VERSION" clamav.spec
echo fedpkg new-sources ${TARBALL_CLEAN} $main_ver $daily_ver $bytecode_ver
echo Press enter scratch-build or n to skip ; read dummy;
if [[ "$dummy" != "n" ]]; then
#fkinit -u sergiomb
@ -73,6 +74,7 @@ fedpkg scratch-build --srpm
fi
echo Press enter to upload sources and commit or n to skip; read dummy;
if [[ "$dummy" != "n" ]]; then
echo fedpkg new-sources ${TARBALL_CLEAN} $main_ver $daily_ver $bytecode_ver
fedpkg new-sources ${TARBALL_CLEAN} $(spectool -l clamav.spec | grep -P "Source10|Source11|Source12" | sed 's/.* //')
fedpkg ci -c && git show
fi