PureOS package sources?

In Debian, you can run “aptitude source {package name}” to download the source code used to build a given package, complete with any Debian-specific patches that went into it. However, when I tried that on PureOS, I got an error message saying that PureOS didn’t have any source URIs configured. In other words, no “deb-src” lines in the “sources.list” file. What would be the URIs of the source repos for PureOS? Or alternatively, how else would I acquire a copy of the code used to build a given package in the PureOS package repo?

1 Like

I think you can navigate around here and find sources
https://repo.puri.sm/

1 Like

(Edit: updated from green to amber.)

You can do this two ways;

  1. Through the ‘Software’ app
  2. Via the command line

Via the command line is a bit more reliable. I outline the steps below;

  • Use an editor to edit your /etc/apt/sources.list file
    – I use sudo emacs /etc/apt/sources.list sudo is required because root owns this file.
  • Insert deb-src https://repo.puri.sm/pureos amber main into the file exactly as written.
  • apt-get update
  • apt-get source <package_name> will now work

This is just a small change but hacking on your /etc/apt/sources.list can cause problems so one ought to take care.

You can also view all our source code on our Gitlab: https://source.puri.sm/pureos/packages

3 Likes

Yes, this is true. We’re also moving to repo.pureos.net/pureos to disambiguate between Purism and PureOS a little bit.

Awesome. And the repo is even compatible with apt-get, so no need to search through the directories in a Web browser by hand. Thank you!

1 Like

Should that “green” in

  • Insert deb-src https://repo.puri.sm/pureos green main into the file exactly as written.

be “amber” or something else by now?

Then “<package_name>” should be the same as for apt show or dpkg, right?

TIA :slight_smile:

Ping :wink:
Am I being too impatient?
Sorry if so…

Maybe reviving an old question works differently?
My post that I’m now replying to doesn’t show up
when I click my letter-P “avatar” which brings up my other posting history.

So I’m wondering if this is visible to others not specifically searching…
Thanks.

It shows up under search, but it does seem like it didn’t actually register new activity or anything (I don’t see this post grouped with all the other recently-posted-in threads)

As for your question, yes, I think you should go with “amber” if you want the stable version or “byzantium” if you want newer versions of packages at the risk of maybe having an update occasionally break some things. And I do think the package name would be what shows up with apt search.

2 Likes

Thank you for understanding my questions and replying
informatively on (my) topic :slight_smile:

1 Like

Yes, it should be ‘Amber’. :slight_smile: