Skip site navigation (1)Skip section navigation (2)

FreeBSD Manual Pages

  
 
  

home | help
PKG_CUTLEAVES(1)	     General Commands Manual		PKG_CUTLEAVES(1)

NAME
     pkg_cutleaves -- deinstall 'leaf' packages

SYNOPSIS
     pkg_cutleaves [-cglRVx]

DESCRIPTION
     pkg_cutleaves  finds  installed "leaf" packages, i.e. packages that are not
     referenced by any other installed package, and lets you decide for each one
     if you want to keep or deinstall it (via pkg-delete(1)). Once the	packages
     marked  for  removal  have been flushed/deinstalled, you'll be asked if you
     want to do another run (i.e. to see packages that have become 'leaves'  now
     because you've deinstalled the package(s) that depended on them.  Note: see
     -R  below	to bypass interactive dependency removal). In every run you will
     be  shown	only  packages	that  you  haven't  marked  for  keeping,   yet.
     pkg_cutleaves.

OPTIONS
     The following command line arguments are supported:

     -c  When  listing	leaf  packages, also print their comments/short descrip-
	 tions. Will be ignored unless the -l parameter is given, too.

     -L  Interpret exclude file as a list of leaf packages that  should  be  in-
	 stalled.  Report lint such as lines that match no installed packages or
	 excluded packages that are not leaves.

     -g  Generate the exclude list from kept or installed (when run with  -l  or
	 -L) leaf packages.

     -l  List leaf packages only, one per line, and don't ask for anything to be
	 deinstalled.

     -V  Visual mode. Will compile a list of leaf packages and invoke the user's
	 EDITOR.   Lines  or  package  names that are deleted in the editor will
	 then be removed.

     -R  Autoprune mode. Automatically deinstall non-required packages on  which
	 the removed leaf packages depended. Will not remove packages on the ex-
	 clude list if -x is also in effect.

     -x  Exclude packages matching expressions given in the exclude file.

EXAMPLES
     *	 Interactively cut leaf packages using the current exclude list:

	       pkg_cutleaves -x

     *	 List all current leaf packages with comments:

	       pkg_cutleaves -lc

     *	 List  packages not currently excluded and regenerate a new exclude file
	 with both the listed and previously excluded packages:

	       pkg_cutleaves -lxg

     *	 Interactively cut current leaf packages  and  remove  newly  discovered
	 leaves, i.e. dependencies, automatically:

	       pkg_cutleaves -R

     *	 The  same  as	the previous example but use the current exclude list to
	 filter all first-level leaves and any newly discovered leaves. Generate
	 a new exclude file with the remaining leaves:

	       pkg_cutleaves -Rxg

     *	 Find exclude patterns that match nothing and those that match	required
	 packages, i.e. non-leaves:

	       pkg_cutleaves -L

FILES
     /usr/local/etc/pkg_leaves.exclude
	     An  optional  list for excluding packages when the -x or -L options
	     are given. If the beginning of a package's name  matches  any  line
	     (except  comment or empty lines) in this file, the package will not
	     be listed/offered for removal (e.g., a  line  saying  just  XFree86
	     will exclude all packages with names starting with "XFree86" ). The
	     list can be auto-generated with the -g option.

ENVIRONMENT
     The following environment variables will be used in visual mode:

     EDITOR  The editor specified by the variable EDITOR will be invoked instead
	     of the default editor vi(1).

SEE ALSO
     pkg(8), pkg-info(8), portsclean(1)

AUTHOR
     Stefan Walter <sw@gegenunendlich.de>

FreeBSD 			 March 20, 2008 		PKG_CUTLEAVES(1)

Want to link to this manual page? Use this URL:
<https://man.freebsd.org/cgi/man.cgi?query=pkg_cutleaves&sektion=1&manpath=FreeBSD+Ports+15.1.quarterly>

home | help