Wie kann ich alle URLs der Abhängigkeiten eines Deb-Pakets erhalten?

Wie kann ich alle URLs der Abhängigkeiten eines Deb-Pakets erhalten?

Ich möchte prüfen, ob es möglich ist, die URLs aufzulisten, die für alle Abhängigkeiten für ein bestimmtes System benötigt werden.

Nehmen wir an, ich möchte eine Software installieren, die von über 100 einzelnen Paketen abhängt und ich muss einige Dutzend solcher Pakete besorgen. Dabei befinde ich mich in einem restriktiven Proxy (natürlich zur Hölle!!!), der mich auffordert, jede URL anzugeben, auf die ich Zugriff benötige.

Ich habe herausgefunden, dass ich apt-rdepends verwenden kann, um eine Liste der abhängigen Pakete zu erhalten. Aber wie bekomme ich die Abhängigkeiten korrekt zu URLs (vorausgesetzt, *.ubuntu.com ist okay)

Antwort1

--print-urisSie können apt-get und die Option zum Anzeigen von URIs verwenden :

sudo apt-get --print-uris install geany
Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following extra packages will be installed:
  geany-common
Suggested packages:
  libvte9
The following NEW packages will be installed:
  geany geany-common
0 upgraded, 2 newly installed, 0 to remove and 0 not upgraded.
Need to get 3,242 kB of archives.
After this operation, 8,894 kB of additional disk space will be used.
Do you want to continue [Y/n]? y
'http://archive.ubuntu.com/ubuntu/pool/universe/g/geany/geany-common_1.22+dfsg-2ubuntu1_all.deb' geany-common_1.22+dfsg-2ubuntu1_all.deb 2153292 MD5Sum:e7dc7ca72d4e3b27ebfeadaea9fb3289
'http://archive.ubuntu.com/ubuntu/pool/universe/g/geany/geany_1.22+dfsg-2ubuntu1_amd64.deb' geany_1.22+dfsg-2ubuntu1_amd64.deb 1089150 MD5Sum:e201bf70fc0ef23b0f64c410125814cb

Dies ist die einfachste Methode und erfordert keine zusätzliche Installation.

apt-get man-Auszug:

--print-uris
       Instead of fetching the files to install their URIs are printed. Each URI will have the path, the
       destination file name, the size and the expected MD5 hash. Note that the file name to write to
       will not always match the file name on the remote site! This also works with the source and update
       commands. When used with the update command the MD5 and size are not included, and it is up to the
       user to decompress any compressed files. Configuration Item: APT::Get::Print-URIs.

verwandte Informationen