On 8/16/07, Jonas Karlsson <[EMAIL PROTECTED]> wrote:
> I don't know what happened (well I do, but I'm still pretty chocked), but I
> nearly had a wipeout with PutRecipe! Luckily I was looking with half an eye
> when I saw lots of "normal" files, text files, documents, images, logs etc,
> scroll by and once in a while intermixed with a message that said "rm:
> cannot remove `foo': Is a directory". Can anyone guess how frenetically I
> started to press ctrl-c? :D
>
> It was the section below, from UpdateRecipeStore, that was responsible:
>
> # Loop 2: remove revision tarballs which doesn't exist anymore in the svn.
> cd $compileLocalStore
> for i in *
> do
>      svn_dir=$compileLocalRevisions/`echo $i | sed
> 's,\(.*\)--\(.*\)--recipe.tar.bz2,\1/\2,g'`
>      [ -d "$svn_dir" ] || { echo $i; rm $i; };
> done
>
> $compileLocalStore is defined in DevelScripts/CompileSubversion.conf but
> that isn't applied unless one has run 'UpdateSettings DevelScripts' after
> updated from the cvs repo. Just how often do _you_ run UpdateSettings after
> having done a 'cvs up' on any tools? Changes like these should either come
> with a *big* warning or have a fallback if some variable is undefined. Now
> '*' in the for loop expanded to everything in that users home directory, as
> 'cd' without arguments goes there. Fortunatly I never user my superuser
> account for anything useful and superuser is the only one that can commit
> recipes, due to permission bugs. So nothing important was lost, but I still
> count this as a close call.

Ouch. Actually, now that the server is maintaining the recipe store
from svn all by itself, we no longer need to/should run
UpdateRecipeStore to do the explicit remote push. I'm removing it from
CVS and adding some default fallback values in PutRecipe. I should
have done this as soon as the new scheme got stable, sorry about the
mess.

> PS. Remember to run UpdateSettings if you track cvs!

Seconded -- this is good advice.

-- Hisham
_______________________________________________
gobolinux-devel mailing list
gobolinux-devel@lists.gobolinux.org
http://lists.gobolinux.org/mailman/listinfo/gobolinux-devel

Reply via email to