Changeset 129054


Ignore:
Timestamp:
Dec 4, 2014, 7:23:54 PM (5 years ago)
Author:
cal@…
Message:

base: document port provides, #44530

File:
1 copied

Legend:

Unmodified
Added
Removed
  • trunk/base/doc/port-provides.1.txt

    r129052 r129054  
    11// vim: set et sw=4 ts=8 ft=asciidoc tw=80:
    2 port-contents(1)
     2port-provides(1)
    33================
    44$Id$
     
    66NAME
    77----
    8 port-contents - List the files installed by a given port
     8port-provides - Find the port that installed a file
    99
    1010SYNOPSIS
    1111--------
    1212[cmdsynopsis]
    13 *port* [*-q*] [*-D* 'portdir'] *contents*
    14      [--size] [--units 'unit']
    15      [['portname' | 'pseudo-portname' | 'port-expressions' | 'port-url']]
     13*port* *provides* 'file' ...
    1614
    1715DESCRIPTION
    1816-----------
    19 *port contents* displays a list of all files that have been installed by a given
    20 port. You can only use *contents* for ports that are 'active' and installed.
     17*port provides* looks up which port installed a given file, if the file has been
     18installed by MacPorts. If the given file is not known to MacPorts it was either
     19obtained using a different method, or has been created by a script or an
     20executable after installation.
    2121
    22 Common uses for *contents* include finding the location of a port's executable
    23 after installing it. You can combine *port contents* with other tools to
    24 simplify this, e.g.
     22All files that are part of a port will be removed when you uninstall said port.
     23For this reason, configuration files are often not registered to a port to
     24preserve modifications across updates.
     25
     26[NOTE]
     27You can only use *provides* on files that you have installed on your system.
     28MacPorts does currently not have a global database of files. If you're looking
     29for the port that provides a specific file, *provides* is useless to you.
     30
     31BUGS
    2532----
    26 port -q contents asciidoc | grep -E '/s?bin/'
    27 ----
    28 
    29 OPTIONS
    30 -------
    31 
    32 *--size*::
    33     Enable printing a human-readable representation of the files' sizes. The
    34     size output can be adjusted using the *--units 'unit'* flag.
    35 
    36 *--units 'unit'*::
    37     Used in conjunction with *--size* to choose the unit in which the size is
    38     given. Valid values for 'unit' are
    39 
    40     *B*:::
    41         List sizes in bytes.
    42 
    43     *K*, *Ki*, *KiB*:::
    44         List sizes in KiB, i.e., 1024 bytes.
    45 
    46     *Mi*, *MiB*:::
    47         List sizes in MiB, i.e., 1024 * 1024 bytes.
    48 
    49     *Gi*, *GiB*:::
    50         List sizes in GiB, i.e., 1024 * 1024 * 1024 bytes.
    51 
    52     *k*, *kB*:::
    53         List sizes in kB, i.e., 1000 bytes.
    54 
    55     *M*, *MB*:::
    56         List sizes in MB, i.e., 1000 * 1000 bytes.
    57 
    58     *G*, *GB*:::
    59         List sizes in GB, i.e., 1000 * 1000 * 1000 bytes.
    60 
    61 
    62 include::global-flags.txt[]
    63 
    64 *-q*::
    65     Do not print the header line.
    66 
     33If MacPorts is configured to use a prefix that contains symlinks, *provides* may
     34incorrectly report that a file is unknown to MacPorts.
    6735
    6836SEE ALSO
    6937--------
    70 man:port[1], man:grep[1]
     38man:port[1], man:port-contents[1]
    7139
    7240AUTHORS
Note: See TracChangeset for help on using the changeset viewer.