How to make yum download srpms too?

Jitesh Shah jitesh.1337 at gmail.com
Sat Aug 27 17:35:59 UTC 2011


..snip..

On Sat, Aug 27, 2011 at 12:59 PM, Fernando Cassia <fcassia at gmail.com> wrote:
> Is there any way to make yum also download srpms for every downloaded (and
> installed) rpm?.
>
> I just want to keep a repository of source files needed to build a system in
> any given state it currently is. For instance, I can download the srpms for
> the base system, but as time passes, the system will auto-download security
> fixes and other app updates... I'd love the srpms for each to be downloaded
> automagically and placed in, say /home/userX/source-updates/
>
> how would you approach this? is it needed to patch yum? or RPM? or maybe
> there's an existing mechanism to accomplish this?

You could may be use "rpm -qa" to get a list of all installed RPMs and
then pipe the output to "yumdownloader --source" to download SRPMs for
all installed RPMs. That is assuming you don't need tight integration
with yum.

Jitesh


More information about the users mailing list