commit:     3cd8bfde8bf2f6f408706bab10600ef96443d91b
Author:     Fabian Groffen <grobian <AT> gentoo <DOT> org>
AuthorDate: Wed Aug 17 19:26:40 2022 +0000
Commit:     Fabian Groffen <grobian <AT> gentoo <DOT> org>
CommitDate: Wed Aug 17 19:26:40 2022 +0000
URL:        https://gitweb.gentoo.org/repo/proj/prefix.git/commit/?id=3cd8bfde

scripts/rsync-generation/update-rsync-master: zap any changes before pull

Somehow the git trees can get dirty, ensure they are completely clean
each time.

Signed-off-by: Fabian Groffen <grobian <AT> gentoo.org>

 scripts/rsync-generation/update-rsync-master.sh | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/scripts/rsync-generation/update-rsync-master.sh 
b/scripts/rsync-generation/update-rsync-master.sh
index d345da831e..d2e72ffec6 100755
--- a/scripts/rsync-generation/update-rsync-master.sh
+++ b/scripts/rsync-generation/update-rsync-master.sh
@@ -106,6 +106,7 @@ GLOBALSTART=${START}
 echo "($(date +"%F %R")) updating DTDs"
 pushd "$DTDDIR" || exit 1
 fromcommit=$(git log --pretty=format:'%H' -n1)
+git checkout -q .
 git clean -dfq
 git pull -q
 tocommit=$(git log --pretty=format:'%H' -n1)
@@ -120,6 +121,7 @@ echo "($(date +"%F %R")) set date to $(< 
"${RSYNCDIR}"/metadata/dtd/timestamp.ch
 echo "($(date +"%F %R")) updating GLSAs"
 pushd "$GLSADIR" || exit 1
 fromcommit=$(git log --pretty=format:'%H' -n1)
+git checkout -q .
 git clean -dfq
 git pull -q
 tocommit=$(git log --pretty=format:'%H' -n1)
@@ -134,6 +136,7 @@ echo "($(date +"%F %R")) set date to $(< 
"${RSYNCDIR}"/metadata/glsa/timestamp.c
 echo "($(date +"%F %R")) updating news"
 pushd "$NEWSDIR" || exit 1
 fromcommit=$(git log --pretty=format:'%H' -n1)
+git checkout -q .
 git clean -dfq
 git pull -q
 tocommit=$(git log --pretty=format:'%H' -n1)
@@ -162,6 +165,7 @@ START=$(date +%s)
 echo "($(date +"%F %R")) updating the gx86 tree"
 pushd "${GENTOOX86DIR}" || exit 1
 fromcommit=$(git log --pretty=format:'%H' -n1)
+git checkout -q .
 git clean -dfq
 git pull -q
 tocommit=$(git log --pretty=format:'%H' -n1)
@@ -189,6 +193,7 @@ START=$(date +%s)
 echo "($(date +"%F %R")) updating Prefix tree (Git image)"
 pushd "$PREFIXTREEDIR" || exit 1
 fromcommit=$(git log --pretty=format:'%H' -n1)
+git checkout -q .
 git clean -dfq
 git pull -q
 tocommit=$(git log --pretty=format:'%H' -n1)

Reply via email to