Page MenuHomeFreeBSD

D18497.id51831.diff
No OneTemporary

D18497.id51831.diff

Index: en_US.ISO8859-1/books/handbook/ports/chapter.xml
===================================================================
--- en_US.ISO8859-1/books/handbook/ports/chapter.xml
+++ en_US.ISO8859-1/books/handbook/ports/chapter.xml
@@ -627,12 +627,12 @@
</sect2>
<sect2 xml:id="pkgng-autoremove">
- <title>Automatically Removing Leaf Dependencies</title>
+ <title>Automatically Removing Unused Packages</title>
<para>Removing a package may leave behind dependencies which
are no longer required. Unneeded packages that were installed
- as dependencies can be automatically detected and removed
- using:</para>
+ as dependencies (leaf packages) can be automatically detected
+ and removed using:</para>
<screen>&prompt.root; <userinput>pkg autoremove</userinput>
Packages to be autoremoved:
@@ -642,6 +642,49 @@
Proceed with autoremoval of packages [y/N]: <userinput>y</userinput>
Deinstalling ca_root_nss-3.15.1_1... done</screen>
+
+ <para>Packages installed as dependencies are
+ called <emphasis>automatic</emphasis> packages. Non-automatic
+ packages, i.e the packages that were explicity installed not
+ as a dependency to another package, can be listed
+ using:</para>
+
+ <screen>&prompt.root; <userinput>pkg prime-list</userinput>
+nginx
+openvpn
+sudo</screen>
+
+ <para><command>pkg prime-list</command> is an alias command
+ declared in <filename>/usr/local/etc/pkg.conf</filename>.
+ There are many others that can be used to query the package
+ database of the system. For instance, command
+ <command>pkg prime-origins</command> can be used to get the
+ origin port directory of the list mentioned above:</para>
+
+ <screen>&prompt.root; <userinput>pkg prime-origins</userinput>
+www/nginx
+security/openvpn
+security/sudo</screen>
+
+ <para>This list can be used to rebuild all packages
+ installed on a system using build tools such as <package>
+ ports-mgmt/poudriere</package> or <package>
+ ports-mgmt/synth</package>.</para>
+
+ <para>Marking an installed package as automatic can be
+ done using:</para>
+
+ <screen>&prompt.root; <userinput>pkg set -A 1 devel/cmake</userinput></screen>
+
+ <para>Once a package is a leaf package and is marked
+ as automatic, it gets selected by
+ <command>pkg autoremove</command>.</para>
+
+ <para>Marking an installed package as <emphasis>not</emphasis>
+ automatic can be done using:</para>
+
+ <screen>&prompt.root; <userinput>pkg set -A 0 devel/cmake</userinput></screen>
+
</sect2>
<sect2 xml:id="pkgng-backup">

File Metadata

Mime Type
text/plain
Expires
Tue, Jun 23, 3:48 AM (8 h, 9 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
34228944
Default Alt Text
D18497.id51831.diff (2 KB)

Event Timeline