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

Re: vcswatch



Re: Thomas Goirand 2014-08-02 <[🔎] 53DCA08D.8040708@debian.org>
> The problem is that between the initial "git clone" and the subsequent
> "git fetch", it is possible that the default branch of the remote bare
> repository has changed, and therefore, vcswatch may continue to use the
> wrong branch as the default packaging branch.

Git is just weird (there).

> 1- Have somewhere on the web interface, some button to ask for a full
> re-clone of the package.

I'm hesitant to add this without auth. What I'd like to have myself is
a way for people to say "the repository has changed, please look at
$otherurl until the next upload". Requesting a re-clone would be a
similar action. I might look into adding auth support via dacs, though
that would take some time unless someone else gets onto it.

> 2- Every now and then (every week?) do a full reclone

Nak.

> 3- If qa.debian.org can have ssh access to Alioth, then something like
> this would do:
> ssh git.debian.org 'cd /git/openstack/nova.git && git branch | grep \\*'

I'm specifically not shortcutting http access via ssh because I want
to trap errors like "no git update-server-info was run". Now, just
fetching the HEAD info via ssh would work, but that'd be a gross hack.


Re: Raphael Hertzog 2014-08-02 <[🔎] 20140802090202.GA7291@x230-buxy.home.ouaza.com>
> $ git ls-remote https://alioth.debian.org/anonscm/git/openstack/ceilometer.git|grep HEAD
> 
> This will give you the commit corresponding to the default branch. You can
> then just checkout that commit.

Nod. I'll look into this.


Re: Thomas Goirand 2014-08-02 <[🔎] 53DD0BA5.1020601@debian.org>
> HEADREF=`git ls-remote
> https://alioth.debian.org/anonscm/git/openstack/ceilometer.git | grep
> HEAD | awk '{print $1}'`
> 
> git ls-remote
> https://alioth.debian.org/anonscm/git/openstack/ceilometer.git | grep
> ${HEADREF} | grep refs/heads | awk '{print $2}' | sed 's#refs/heads/##'
> 
> Is there something quicker than 2 "git ls-remote" calls?

LSREMOTE=$(git ls-remote ...)
HEADREF=$(echo "$LSREMOTE" | grep ...)

> Christoph, do you think you could add this check in vcswatch? I don't
> think I'm good enough in perl to do it in a non-too-hackish way.

Well it is actually a shell script disguised as Perl, so that wouldn't
matter much ;)

I'll get onto it over the next days. Thanks for the prod, I had though
I'd fixed this.

Christoph
-- 
cb@df7cb.de | http://www.df7cb.de/


Reply to: