Mailinglist Archive: opensuse-buildservice (258 mails)

< Previous Next >
Re: [opensuse-buildservice] Integrating SCM with OBS
  • From: Adrian Schröter <adrian@xxxxxxx>
  • Date: Fri, 13 Aug 2010 12:04:09 +0200
  • Message-id: <201008131204.09958.adrian@xxxxxxx>
On Friday 13 August 2010 11:31:05 Marcus Meissner wrote:
On Fri, Aug 13, 2010 at 11:23:30AM +0200, Adrian Schröter wrote:


This all is way too bloated.

I mean you can just use a simple osc client checkout/update/checkout.

Feed in some kind lists and you are set.

e.g. for wine in OBS I have this simple script which pulls daily git
snapshots, including detecting unchanged state and seperating local

#!/bin/bash -x
xdate=`date +%Y%m%d`

cd $bsdir
cd $snapdir/wine
git pull
chars=`git diff '@{1 day ago}' | wc -c`
if [ "$chars" == "0" ]; then
echo "*** No git change found from yesterday, not rebuilding
exit 0
rm $bsdir/wine-*.tar.bz2
winever=`cat VERSION|sed -e 's/Wine version //;s/1.2-/1.2./;'`
git archive origin --prefix=wine-$winever.$xdate/ | bzip2
# perhaps split into seperate patches
git diff origin..master > $bsdir/susepatches.patch
cd $bsdir
perl -pi -e "s/Version:.*/Version:$winever.$xdate/;" wine-snapshot.spec
osc addremove
osc ci -m "$xdate git checkout"

So why not just write such little helpers for tar downloads, git
checkouts, svn checkouts, and then use a simple list or XML file as

Should really be doable in 200 lines of code, all client-side, without lots of
server magic.

Well, the download_url is way less bash script code.

And you can run services always on the server and on the client.

But with server side execution you have ensured that the source is really
comming from
the configured origin. And others can do it in the same way, so it is not a
specific hack in
your private home.

Adrian Schroeter
SUSE Linux Products GmbH
email: adrian@xxxxxxx
To unsubscribe, e-mail: opensuse-buildservice+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: opensuse-buildservice+help@xxxxxxxxxxxx

< Previous Next >