The dget command in Linux is a tool used to download Debian source packages from a Debian package archive using the command line. It is typically used by developers and advanced users to download packages for building and testing. The dget command is part of the devscripts package in Debian-based distributions such as Ubuntu, and can be installed using the package manager. Once installed, the dget command can be used by providing the URL of the package to download. For example, “dget http://ftp.debian.org/debian/pool/main/p/package/package_version.dsc” will download the source package for “package” at version “version” from the Debian archive.
dget Command Examples
1. Download a binary package:
# dget package_name
2. Download and extract a package source from its `.dsc` file:
# dget http://deb.debian.org/debian/pool/main/h/haskell-tldr/haskell-tldr_0.4.0-2.dsc
3. Download a package source tarball from its `.dsc` file but don’t extract it:
# dget -d http://deb.debian.org/debian/pool/main/h/haskell-tldr/haskell-tldr_0.4.0-2.dsc