Using yum within a program

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi, I am relatively new to programming on POSIX and would like some advice on using yum within a program.
When a certain event happens in my program (written in JAVA), I want to install a package onto the system. I was looking into java.lang.Runtime's exec() function which can be used to execute command(s) as a separate process. But this becomes tricky in some cases. For example, when the user is not logged in as root, yum requires authentication and this involves using buffered readers for command outputs and inputs.

Is there a better way of doing this? Maybe some arguments/options with yum that will decrease the need for user interference? Or use of some scripting languages?

The project I am working on has both command line and GUI components, so a solution compatible/extensible with both would be the best. Thanks in advance for any help.

Cheers,

Teresa




_______________________________________________
Yum mailing list
Yum@xxxxxxxxxxxxxxxxxxxx
https://lists.dulug.duke.edu/mailman/listinfo/yum

[Index of Archives]     [Fedora Users]     [Fedora Legacy List]     [Fedora Maintainers]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]

  Powered by Linux