2 .\" Copyright 1998 Bruce A. Mah
4 .\" All rights reserved.
6 .\" Redistribution and use in source and binary forms, with or without
7 .\" modification, are permitted provided that the following conditions
9 .\" 1. Redistributions of source code must retain the above copyright
10 .\" notice, this list of conditions and the following disclaimer.
11 .\" 2. Redistributions in binary form must reproduce the above copyright
12 .\" notice, this list of conditions and the following disclaimer in the
13 .\" documentation and/or other materials provided with the distribution.
15 .\" THIS SOFTWARE IS PROVIDED BY THE DEVELOPERS ``AS IS'' AND ANY EXPRESS OR
16 .\" IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
17 .\" OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
18 .\" IN NO EVENT SHALL THE DEVELOPERS BE LIABLE FOR ANY DIRECT, INDIRECT,
19 .\" INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
20 .\" NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
21 .\" DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
22 .\" THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
23 .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
24 .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
33 .Nd summarize installed versions of packages
46 .Fl t Ar version1 version2
48 .Fl T Ar pkgname pattern
52 command is used to produce a report of non-base software packages
57 Each package's version number is checked against one of two sources to
58 see if that package may require updating.
59 If the package contains
60 information about its origin in the
62 ports tree, and a version number can be determined from the port's
64 then the version number from the
66 will be used to determine whether the installed package is up-to-date
69 If no origin for a package can be found, or if the port's
73 will search for the package in the ports collection index file
75 .Pa /usr/ports/INDEX-8 ) .
76 Any matching version number(s) there will be used to determine whether
77 the installed package is up-to-date or requires updating.
79 Generally, using the version number from a port's
81 will provide a more accurate result, since, unlike the index file, it
82 provides an unambiguous current version number, even when multiple
83 versions of a port exist in the ports collection.
84 Moreover, the ports collection index file is only updated at
85 intervals, meaning that it may not completely reflect the version
86 numbers of the software contained in the ports collection.
88 Each package name is printed, along with a one-character status flag:
89 .Bl -tag -width indent
91 The installed version of the package is current.
93 The installed version of the package is older than the current version.
95 The installed version of the package is newer than the current version.
96 This situation can arise with an out-of-date index file, or when
99 The installed package does not appear in the index.
100 This could be due to an out of date index or a package taken from a PR
101 that has not yet been committed.
103 There are multiple versions of a particular software package
104 listed in the index file.
107 ports collection are the Tcl toolkit or the
111 The installed package exists in the index but for some reason,
113 was unable to compare the version number of the installed package
114 with the corresponding entry in the index.
119 utility supports several command-line arguments:
120 .Bl -tag -width indent
123 .It Fl I , -index-only
124 Use only the index file for determining if a package is out of date.
125 This is much faster than using the version number from a port's
126 Makefile, at the expense of potentially giving an incorrect result if
127 the index file is out of date.
128 .It Fl l , -status Ar limchar
129 Limit the output to those packages whose status flag matches the
132 More than one character can be specified in
134 Note that because some of the status flag characters are also special
135 to the shell, it is best to quote
138 .It Fl L , -no-status Ar limchar
139 Limit the output to those packages whose status flag does not match
141 You may specify more than one character to match in
143 Note that because some of the status flag characters are also special
144 to the shell, it is best to quote
147 .It Fl o , -show-origin
148 Show the origin recorded on package generation instead of the package
150 .It Fl O , -origin Ar origin
151 Only list packages whose registered origin is
155 Quiet output precludes printing the
161 This is useful when used as the input to
163 .It Fl s , -match Ar string
164 Limit the output to those packages whose names match a given
169 as a extended regular expression.
171 Test a pair of version number strings and exit.
172 The output consists of one of the single characters
176 (right-hand number greater), or
178 (left-hand number greater) on standard output.
179 This flag is mostly useful for scripts or for testing.
185 and set the exit code accordingly.
187 can also be used in `filter mode':
188 When one of the arguments is `-', standard input is used, and lines
189 with matching package names/patterns are echoed to standard output.
191 Enable verbose output.
192 Verbose output includes some English-text
193 interpretations of the version number comparisons, as well as the
194 version numbers compared for each package.
195 Non-verbose output is
196 probably easier for programs or scripts to parse.
198 Specify the index to be used as a basis of comparison.
200 be specified as a filename (in the local file system) or a URL.
202 URL understandable by
207 file is specified on the command line,
208 .Pa /usr/ports/INDEX-8
212 .Bl -tag -width /usr/ports/INDEX-8 -compact
213 .It Pa /usr/ports/INDEX-8
217 The following is a typical invocation of the
219 command, which checks the installed packages against the local ports
224 The command below generates a report against
225 the version numbers in the on-line ports collection:
227 .Dl % pkg_version http://www.FreeBSD.org/ports/INDEX-8
229 The following command compares two package version strings:
231 .Dl % pkg_version -t 1.5 1.5.1
235 option has been deprecated and is no longer supported.
246 utility was written by
247 .An Jeremy D. Lea Aq reg@FreeBSD.org ,
248 partially based on a Perl script written by
249 .An Bruce A. Mah Aq bmah@FreeBSD.org .
251 .An Nik Clayton Aq nik@FreeBSD.org ,
252 .An Dominic Mitchell Aq dom@palmerharvey.co.uk ,
253 .An Mark Ovens Aq marko@FreeBSD.org ,
254 .An Doug Barton Aq DougB@gorean.org ,
255 .An Akinori MUSHA Aq knu@FreeBSD.org ,
256 .An Oliver Eikemeier Aq eik@FreeBSD.org