docs/187351: handbook section on ports does not mention pkg search
Allan Jude
freebsd at allanjude.com
Fri Mar 7 15:50:01 UTC 2014
>Number: 187351
>Category: docs
>Synopsis: handbook section on ports does not mention pkg search
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: freebsd-doc
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: doc-bug
>Submitter-Id: current-users
>Arrival-Date: Fri Mar 07 15:50:00 UTC 2014
>Closed-Date:
>Last-Modified:
>Originator: Allan Jude
>Release: 9.2-RELEASE
>Organization:
ScaleEngine Inc.
>Environment:
FreeBSD Trooper.HML3.ScaleEngine.net 9.2-RELEASE FreeBSD 9.2-RELEASE #0 r255898: Thu Sep 26 22:50:31 UTC 2013 root at bake.isc.freebsd.org:/usr/obj/usr/src/sys/GENERIC amd64
>Description:
The handbook section "5.3. Finding Software" does not mention 'pkg search' as a way to find software. Even for searching the ports tree, this can be useful, but it is especially useful when searching for a package
>How-To-Repeat:
>Fix:
Patch attached
Patch attached with submission follows:
Index: ports/chapter.xml
===================================================================
--- ports/chapter.xml (revision 44112)
+++ ports/chapter.xml (working copy)
@@ -197,9 +197,11 @@
<para>Before installing any application, check <uri
xlink:href="http://vuxml.freebsd.org/">http://vuxml.freebsd.org/</uri>
for security issues related to the application or install
- <package>ports-mgmt/portaudit</package>. Once installed, type
+ <package>ports-mgmt/portaudit</package>. Once installed, type
<command>portaudit -F -a</command> to check all installed
- applications for known vulnerabilities.</para>
+ applications for known vulnerabilities. If you are using
+ <application>pkg</application>, the audit functionality is
+ built in, simply run: <command>pkg audit -F</command>.</para>
</warning>
<para>The remainder of this chapter explains how to use packages
@@ -246,6 +248,61 @@
</listitem>
<listitem>
+ <indexterm>
+ <primary>pkg</primary>
+ <secondary>search</secondary>
+ </indexterm>
+
+ <para xml:id="pkg-search">To search the binary package
+ repository for an application:</para>
+
+ <screen>&prompt.root; <userinput>pkg search <replaceable>subversion</replaceable></userinput>
+git-subversion-1.8.5.2
+java-subversion-1.8.5
+p5-subversion-1.8.5
+py27-hgsubversion-1.5.1
+py27-subversion-1.8.5
+ruby-subversion-1.8.5
+subversion-1.6.23_2
+subversion-1.7.14
+subversion-1.8.5
+subversion-book-4515
+subversion-static-1.8.5</screen>
+
+ <para>Package names include the version number and in the
+ case of ports based on python, the version number of the
+ version of python the package was built with. Some ports
+ also have multiple versions available. In the case of
+ <application>subversion</application> there are different
+ versions available, as well as different compile options,
+ in this case, the staticly linked version of
+ <application>subversion</application>. When indicating
+ which package to install, it is best to specify the
+ application by the port origin, the path in the ports tree.
+ Repeat the <command>pkg search</command> with
+ <option>-o</option> to list the origin of each
+ package:</para>
+
+ <screen>&prompt.root; <userinput>pkg search -o <replaceable>subversion</replaceable></userinput>
+devel/git-subversion
+java/java-subversion
+devel/p5-subversion
+devel/py-hgsubversion
+devel/py-subversion
+devel/ruby-subversion
+devel/subversion16
+devel/subversion17
+devel/subversion
+devel/subversion-book
+devel/subversion-static</screen>
+
+ <para><command>pkg search</command> also supports searching
+ using shell globs, regular expressions, exact match,
+ search by description, or any other field in the
+ repository database. See &man.pkg-search.8;</para>
+ </listitem>
+
+ <listitem>
<para>If the Ports Collection is already installed, there are
several methods to query the local version of the ports
tree. To find out which category a port is in, type
>Release-Note:
>Audit-Trail:
>Unformatted:
More information about the freebsd-doc
mailing list