FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Redhat > Fedora SELinux Support

 
 
LinkBack Thread Tools
 
Old 03-06-2012, 02:55 PM
David Lehman
 
Default Add a property to return the id of the base repo.

---
pyanaconda/packaging/yumpayload.py | 13 ++++++++++++-
1 files changed, 12 insertions(+), 1 deletions(-)

diff --git a/pyanaconda/packaging/yumpayload.py b/pyanaconda/packaging/yumpayload.py
index 350a5e4..03085e3 100644
--- a/pyanaconda/packaging/yumpayload.py
+++ b/pyanaconda/packaging/yumpayload.py
@@ -144,9 +144,20 @@ reposdir=/etc/yum.repos.d,/etc/anaconda.repos.d,/tmp/updates/anaconda.repos.d,/t
###
@property
def repos(self):
- # FIXME: should this return pykickstart Repo or YumRepo?
return self._yum.repos.repos.keys()

+ @property
+ def baseRepo(self):
+ repo_names = [BASE_REPO_NAME, productName.lower(), "rawhide"]
+ base_repo_name = None
+ for repo_name in repo_names:
+ if repo_name in self.repos and
+ self._yum.repos.getRepo(repo_name).enabled:
+ base_repo_name = repo_name
+ break
+
+ return base_repo_name
+
def _repoNeedsNetwork(self, repo):
""" Returns True if the ksdata repo requires networking. """
urls = [repo.baseurl] + repo.mirrorlist
--
1.7.9.1

_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@redhat.com
https://www.redhat.com/mailman/listinfo/anaconda-devel-list
 
Old 03-06-2012, 03:09 PM
Chris Lumens
 
Default Add a property to return the id of the base repo.

> pyanaconda/packaging/yumpayload.py | 13 ++++++++++++-
> 1 files changed, 12 insertions(+), 1 deletions(-)

Looks okay.

- Chris

_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@redhat.com
https://www.redhat.com/mailman/listinfo/anaconda-devel-list
 

Thread Tools




All times are GMT. The time now is 02:38 AM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org