ubuntu get required packages

I often need to have a list of packages that need to be installed in an INTRANET, to do this I need to download the files from an internet connected machine and then to transer the files.

On Internet Connected machine

This machine has NO PACKAGES INSTALLED, except the OS. I have done an apt-get update but that is it.

Software Requiement

  • rdepends
apt-get install rdepends

Simple Download script

#!/bin/bash
product=$1
for a in $(apt-rdepends $product | grep -v "^ " | sort -u)
do
    echo fetching $a
    apt-get download $a
done

Useage

./GetDep.sh python