Ask Your Question

source package lists

asked 2015-07-12 03:53:42 -0500

I'm searching for a method to retrieve source code maintenance urls for packages within fedora. My solution for .deb systems was this:

sudo cat /var/lib/apt/lists/* | grep Vcs-Git | awk '{print $2}' > apt-sources

I don't know how to replicate that for fedora (or for debian, that's just an apt solution)

how do I grab the scm uri for every package available?

edit retag flag offensive close merge delete

3 Answers

Sort by ยป oldest newest most voted

answered 2015-07-13 05:26:42 -0500


Not completely sure why you need that, but the SRPMS are (for rawhide) held here:

You need to create a repo entry for this in order to query/list, or just write a script to walk that tree.

Other options, if you want to download a source package, is to use dnf:

dnf download -source [package]

Regards, Jon

edit flag offensive delete link more

answered 2015-07-13 06:29:36 -0500

mclmmc gravatar image

even if the package isn't installed

dnf info pkg

gives you the right information

[michele@benemerita ~]$ dnf info mariadb
Using metadata from Wed Jul  1 19:43:24 2015 (11 days, 17:37:50 hours old)
Available Packages
Name        : mariadb
Arch        : x86_64
Epoch       : 1
Version     : 10.0.19
Release     : 2.fc21
Size        : 5.8 M
Repo        : updates
Summary     : A community developed branch of MySQL
URL         :
License     : GPLv2 with exceptions and LGPLv2 and BSD
Description : MariaDB is a community developed branch of MySQL.
            : MariaDB is a multi-user, multi-threaded SQL database server.
            : It is a client/server implementation consisting of a server daemon (mysqld)
            : and many different client programs and libraries. The base package
            : contains the standard MariaDB/MySQL client programs and generic MySQL files.
edit flag offensive delete link more


does it return a git url? I'm not currently administrator and can't install DNF yet, even compiling it (unless I avoid root privileges). I don't need the source package to compile, I need the source tree.

Thank you all so much for the quick responses <3

thetoxicarcade gravatar imagethetoxicarcade ( 2015-07-14 11:48:00 -0500 )edit

answered 2015-08-15 19:16:19 -0500

this post is marked as community wiki

This post is a wiki. Anyone with karma >750 is welcome to improve it.

I don't see a download-source command in fedora 22. Is there something similar in dnf now?

edit flag offensive delete link more

Question Tools


Asked: 2015-07-12 03:53:42 -0500

Seen: 238 times

Last updated: Jul 13 '15