[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-devel] [OSSTEST PATCH] adhoc-revtuple-generator: Explicitly specify refs to fetch

Some of the git trees in $c{Repos} may have been created (eg by
earlier versions of git or earlier versions of osstest) without the
  remote.origin.fetch = +refs/heads/*:refs/remotes/origin/*
git config setting.

Pass this refspec explicitly, instead of relying on it being set as
the default.

Amongst other things, this will prevent a possible error during
  git fetch -p origin
  fatal: bad object 3e3d5f6146c3f684f4b7bd71feffc31e1c668754
which is currently appearing in our cron mail.

Signed-off-by: Ian Jackson <Ian.Jackson@xxxxxxxxxxxxx>
 adhoc-revtuple-generator |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/adhoc-revtuple-generator b/adhoc-revtuple-generator
index f94f189..2b04c11 100755
--- a/adhoc-revtuple-generator
+++ b/adhoc-revtuple-generator
@@ -104,7 +104,7 @@ sub git_generator ($) {
             # the "set -e"-disarmament done by "if" leaks into ( ) !
            cd $c{Repos}/$treename
            git remote set-url origin $eff_url
-           git fetch -p origin
+           git fetch -p origin '+refs/heads/*:refs/remotes/origin/*'
             rm -rf $c{Repos}/$treename

Xen-devel mailing list



Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.