Re: Command Line
rkornfeld-N4erKOH/[email protected] Wed, 24 Mar 2004 08:57:22 -0500
| Newsgroups | gmane.linux.redhat.rpm.python |
|---|---|
| Message-ID | <[email protected]> |
Thank you for the information. Is there anywhere you can point me that lists all the available filter variables? Also, is there a site that has some examples of the complete example including callback? Once again Thank you ----- Original Message ----- From: Panu Matilainen <[email protected]> Date: Wednesday, March 24, 2004 2:20 am Subject: Re: [Rpm-python-list] Command Line > On Tue, 23 Mar 2004, Rick Kornfeld wrote: > > > > Are the command line options of RPM available to the programmer in > > rpm-python? For instance, can I use options like -force -nodeps > etc..> Programmatically in python. I know they are available in C/C++. > > The API is available in python as well, but very little to do with > command > line options of rpm :) > > > If so, can someone provide an example program? > > You just set the same transaction/problemfilter flags as you would > in > C/C++. For example the equivalent of --force would be > > ts = rpm.TransactionSet() > ts.setProbFilter(rpm.RPMPROB_FILTER_REPLACEPKG | > rpm.RPMPROB_FILTER_REPLACEOLDFILES | > rpm.RPMPROB_FILTER_REPLACENEWFILES) > ... > ts.run(...) > > - Panu - > _______________________________________________ > Rpm-python-list mailing list > Rpm-python-list-cunTk1MwBs9zPNxIf5reH/[email protected] > https://lists.dulug.duke.edu/mailman/listinfo/rpm-python-list >