[Yum] extra commands in the .repo files

seth vidal skvidal at phy.duke.edu
Thu Mar 3 07:34:56 UTC 2005


> We need some way to know if the .repo we are parsing is indeed a CentOS 
> one and if so which mirror list to look at. There seem to be 2 ways to 
> work this.
> 
> 1. Use filenames (eg. CentOS-BASE.repo)
> 2. Use a command line or marker inside the repo itself, on a # comment 
> line (#->CentOS-Base<- )
> 
> I know that 2. is a kludge and a bad one - but is there any other way to 
> look at this issue ?
> 
> how do we figure out which ones are CentOS repos from a list of 10 .repo 
> files.
> 
> on email, so reply when u can...

Well, what is it that's going to be acting on these files? That's what
needs to determine if they are centos repo files or not.

you could do it via comments in the file but that's gonna be kinda
gross. you could, of course, keep a list of the files which are the ones
provided in the centos yum package and then always work from that list.

depends on what the program has to do.

-sv





More information about the Yum mailing list