Differenza fra il comando dpkg -l e apt-cache-pkgnames

Non importa se ti serve una mano per partire o se vuoi un consiglio avanzato: gli utenti "del Pinguino" hanno una risposta per ogni necessità.
Regole del forum
Rispondi
Avatar utente
balubeto
Livello: DVD-ROM (5/15)
Livello: DVD-ROM (5/15)
Messaggi: 165
Iscritto il: ven lug 12, 2013 10:52 am

Differenza fra il comando dpkg -l e apt-cache-pkgnames

Messaggio da balubeto »

ciao

Qual`e` la differenza fra i comandi dpkg -l e apt-cache pkgnames?

Pongo questa domanda in quanto ho notato che il primo comando non trova alcuni pacchetti che invece trova il secondo.

Come mai?

grazie

ciao
balubeto
System
System
Bot ufficiale TurboLab.it
Bot
Messaggi:
Iscritto il: sab dic 31, 2016 6:19 pm
Contatta: Contatta

Re: Differenza fra il comando dpkg -l e apt-cache-pkgnames

Messaggio da System » mer mar 12, 2014 7:49 pm


Avatar utente
ninja
Livello: Chiavetta USB (8/15)
Livello: Chiavetta USB (8/15)
Messaggi: 487
Iscritto il: lun ago 26, 2013 8:52 pm

Re: Differenza fra il comando dpkg -l e apt-cache-pkgnames

Messaggio da ninja »

Non è più semplice leggere il manuale che chiedere?

Digiti meno caratteri, ci impieghi meno tempo e ottieni maggiore soddisfazione!

Codice: Seleziona tutto

NAME
       dpkg - package manager for Debian

SYNOPSIS
       dpkg [option...] action
...
...
DESCRIPTION
       dpkg  is  a  tool to install, build, remove and manage Debian packages.
       The primary and more user-friendly front-end for dpkg  is  aptitude(1).
       dpkg  itself  is controlled entirely via command line parameters, which
       consist of exactly one action and zero or  more  options.  The  action-
       parameter tells dpkg what to do and options control the behavior of the
       action in some way.

       dpkg can also be used as a front-end to dpkg-deb(1) and  dpkg-query(1).
       The list of supported actions can be found later on in the ACTIONS sec‐
       tion. If any such action is encountered  dpkg  just  runs  dpkg-deb  or
       dpkg-query with the parameters given to it, but no specific options are
       currently passed to them, to use any such option the back-ends need  to
       be called directly.
...
...
dpkg-query actions
              See dpkg-query(1) for more information about the  follow‐
              ing actions.

              -l, --list package-name-pattern...
                  List packages matching given pattern.
              -s, --status package-name...
                  Report status of specified package.
              -L, --listfiles package-name...
                  List files installed to your system from package-name.
              -S, --search filename-search-pattern...
                  Search for a filename from installed packages.
              -p, --print-avail package-name...
                  Display details about package-name, as found in
                  /var/lib/dpkg/available. Users of APT-based frontends
                  should use apt-cache show package-name instead.
...
...
EXAMPLES
       To list packages related to the editor vi(1):
            dpkg -l '*vi*'

...

Codice: Seleziona tutto

NAME
       apt-cache - query the APT cache

SYNOPSIS
       apt-cache [-hvsn] [-o=config string] [-c=file] {[gencaches] |
                 [showpkg pkg...] | [showsrc pkg...] | [stats] | [dump] |
                 [dumpavail] | [unmet] | [search regex] | [show pkg...] |
                 [depends pkg...] | [rdepends pkg...] | [pkgnames prefix] |
                 [dotty pkg...] | [xvcg pkg...] | [policy pkgs...] |
                 [madison pkgs...]}

DESCRIPTION
       apt-cache performs a variety of operations on APT's package cache.
       apt-cache does not manipulate the state of the system but does provide
       operations to search and generate interesting output from the package
       metadata.
...
...
 pkgnames [ prefix ]
           This command prints the name of each package APT knows. The
           optional argument is a prefix match to filter the name list. The
           output is suitable for use in a shell tab complete function and the
           output is generated extremely quickly. This command is best used
           with the --generate option.

           Note that a package which APT knows of is not necessarily available
           to download, installable or installed, e.g. virtual packages are
           also listed in the generated list.

...
...
System
System
Bot ufficiale TurboLab.it
Bot
Messaggi:
Iscritto il: sab dic 31, 2016 6:19 pm
Contatta: Contatta

Re: Re: Differenza fra il comando dpkg -l e apt-cache-pkgnames

Messaggio da System » ven mar 14, 2014 12:10 am


Rispondi
  • Argomenti simili
    Risposte
    Visite
    Ultimo messaggio