[Date Prev][Date Next] [Thread Prev][Thread Next]
[Thread Index]
[Date Index]
[Author Index]
Re: A program in Python to get Source RPM's from cvs
- From: Seth Vidal <skvidal fedoraproject org>
- To: Development discussions related to Fedora <fedora-devel-list redhat com>
- Subject: Re: A program in Python to get Source RPM's from cvs
- Date: Tue, 7 Apr 2009 18:59:46 -0400 (EDT)
On Tue, 7 Apr 2009, Paty Constantino wrote:
Hi everyone,
I'm doing a program in Python, which for now is taking an application name and gives you the corresponding source rpm, if
you run the program the first thing that will appear is this:
Here's the equivalent using the yum modules:
import yum
import rpmUtils.miscutils
my = yum.YumBase()
my.conf.cache = 1
p = my.pkgSack.searchNevra(name='yum')[0]
print rpmUtils.miscutils.splitFilename(p.sourcerpm)
that should give you a tuple of name, ver, release, arch
also see yumdownloader --source
-sv
[Date Prev][Date Next] [Thread Prev][Thread Next]
[Thread Index]
[Date Index]
[Author Index]