X-Git-Url: https://git.saurik.com/apt.git/blobdiff_plain/7146a53c4c6803bff0ddec739f5ca83231cb2b14..9b5d79ec68d5380f26b92cd0d9cb7af6a19ac849:/cmdline/apt-cache.cc diff --git a/cmdline/apt-cache.cc b/cmdline/apt-cache.cc index d73111b6a..b16a0e5d0 100644 --- a/cmdline/apt-cache.cc +++ b/cmdline/apt-cache.cc @@ -555,6 +555,7 @@ bool Depends(CommandLine &CmdL) bool Recurse = _config->FindB("APT::Cache::RecurseDepends",false); bool Installed = _config->FindB("APT::Cache::Installed",false); + bool Important = _config->FindB("APT::Cache::Important",false); bool DidSomething; do { @@ -577,7 +578,12 @@ bool Depends(CommandLine &CmdL) for (pkgCache::DepIterator D = Ver.DependsList(); D.end() == false; D++) { - + // Important deps only + if (Important == true) + if (D->Type != pkgCache::Dep::PreDepends && + D->Type != pkgCache::Dep::Depends) + continue; + pkgCache::PkgIterator Trg = D.TargetPkg(); if((Installed && Trg->CurrentVer != 0) || !Installed) @@ -1270,7 +1276,7 @@ bool DisplayRecord(pkgCache::VerIterator V) /*}}}*/ // Search - Perform a search /*{{{*/ // --------------------------------------------------------------------- -/* This searches the package names and pacakge descriptions for a pattern */ +/* This searches the package names and package descriptions for a pattern */ struct ExDescFile { pkgCache::DescFile *Df;