How to list, add and remove repositories with yum python API?
fedora, package, python, repository, yum
Solution
you can use eulfedora
eulfedora.api provides complete access to the Fedora API, primarily making use of Fedora's REST API. This low-level interface is wrapped by eulfedora.server.Repository and eulfedora.models.DigitalObject, which provide a more abstract, object-oriented, and Pythonic way of interacting with a Fedora Repository or with individual objects and datastreams.
Problem
How can I search for installed repostiries, add and delete them with yum python API (under fedora 17). I've searched tons of websites and I have found how to manage packages (like here: http://phacker.org/2008/06/20/yum-python-api/), but I have not found anywhere how to handle repositories). I want for example to be able to get with python yum API the same result as: ``` yum repolist yum localinstall --nogpgcheck http://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-stable.noarch.rpm http://download1.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-stable.noarch.rpm` ``` (the last is simmilar to `yum-config-manager --add-repo; yum-config-manager --enable`) etc.