LinuxSir.cn,穿越时空的Linuxsir!

 找回密码
 注册
搜索
热搜: shell linux mysql
查看: 734|回复: 2

gentoolkit update--一个新加的重要工具eclean

[复制链接]
发表于 2006-2-1 19:42:37 | 显示全部楼层 |阅读模式
gentoolkit update

A new version of app-portage/gentoolkit (0.2.1) containing significant improvements has been marked stable a few days ago. These are the major changes between gentoolkit-0.2.0 and gentoolkit-0.2.1:

    * A new tool called eclean for removing no longer needed distfiles and packages has been added
    * revdep-rebuild now allows for more user interaction and customizing. You can avoid rebuilding binary packages like app-office/openoffice-bin by setting the SEARCH_DIRS_MASK variable in /etc/make.conf to for example skip packages installed in the /opt directory.
    * One major fix optimizing memory consumption has been applied to equery. Also many fixes made it more usable, though it is still not the fastest program on the block. If the lack of speed bothers you, we would recommend investigating the app-portage/portage-utils package

A detailed listing of the changes for those interested is in /usr/share/doc/gentoolkit-0.2.1/ChangeLog.
 楼主| 发表于 2006-2-1 20:03:36 | 显示全部楼层

说明

eclean(1)                                                                                                    eclean(1)



NAME
       eclean - A cleaning tool for Gentoo distfiles and binary packages.

SYNOPSIS
       eclean [global-options] ... <actions> [action-options] ...

       eclean-dist [global-options, distfiles-options] ...

       eclean-pkg [global-options, packages-options] ...

       eclean(-dist,-pkg) [--help, --version]

DESCRIPTION
       eclean is small tool to remove obsolete portage sources files and binary packages.  Used on a regular basis, it
       prevents your DISTDIR and PKGDIR directories to infinitely grow, while not deleting files which  may  still  be
       useful.

       By default, eclean will protect all distfiles or binary packages corresponding to some ebuilds available in the
       Portage tree.  This is the safest mode, since it will protect whatever may still be  useful,  for  instance  to
       downgrade  a package without downloading its sources for the second time, or to reinstall a package you unmerge
       by mistake without recompiling it.  Sure, it's also a mode in which your DISTDIR and PKGDIR  will  stay  rather
       big  (although  still not growing infinitly).  For the 'distfiles', this mode is also quit slow mode because it
       requiries some access to the whole Portage tree.

       If you use the --destructive option, eclean will only protect files corresponding to some  currently  installed
       package  (taking  their  exact  version  into  account).   It will save much more space, while still preserving
       sources files around for minor revision bumps, and binaries for reinstallation of corrupted packages.   But  it
       won't  keep files for less usual operations like downgrading or reinstalling an unmerged package.  This is also
       the fastest execution mode (big difference for distfiles), and the one used  by  most  other  cleaning  scripts
       around like yacleaner (at least in its version 0.3).

       Somewhere  in  the middle, adding the --package-names option when using --destructive will protect files corre-
       sponding to all existing versions of installed packages.  It will allow easy downgrading without  recompilation
       or redownloading in case of trouble, but won't protect you against package uninstallation.

       In addition to this main modes, some options allow to declare a few special cases file protection rules:

       o      --time-limit is useful to protect files which are more recent than a given amount of time.

       o      --size-limit (for distfiles only) is useful if you want to protect files bigger than  a given size.

       o      --fetch-restricted  (for  distfiles only) is useful to protect manually downloaded files.  But it's also
              very slow (again, it's a reading of the whole Portage tree data)...

       o      Finally, you can list some categories or package names to protect  in  exclusion  files  (see  EXCLUSION
              FILES below).

PARAMETERS
   Global options
       -C, --nocolor                 turn off colors on output

       -d, --destructive             only keep the minimum for a reinstallation

       -e, --exclude-file=<path>     path to the exclusion file
              <path>  is  the  absolute  path  to  the  exclusion file you want to use.  When this option is not used,
              default paths are /etc/eclean/{packages,distfiles}.exclude (if they exist).  Use /dev/null if  you  have
              such a file at it standard location and you want to temporary ignore it.

       -i, --interactive          ask confirmation before deleting

       -n, --package-names       protect all versions (--destructive only)

       -p, --pretend              only display what would be cleaned

       -q, --quiet                be as quiet as possible, only display errors

       -t, --time-limit=<time>    don't delete files modified since <time>
              <time> is an amount of time: "1y" is "one year", "2w" is "two weeks", etc.
              Units are: y (years), m (months), w (weeks), d (days) and h (hours).

       -h, --help                 display the help screen

       -V, --version              display version informations

   Actions
       distfiles
              Clean  files  from  /usr/portage/distfiles  (or  whatever else is your DISTDIR in /etc/make.conf).  This
              action should be useful to almost any Gentoo user, we all have to big DISTDIRs sometime...
              eclean-dist is a shortcut to call eclean with the "distfiles" action, for simplified command-line.

       packages
              Clean files from /usr/portage/packages (or whatever else is your PKGDIR in /etc/make.conf).  This action
              is in particular useful for people who use the "buildpkg" or "buildsyspkg" FEATURES flags.
              eclean-pkg is a shortcut to call eclean with the "packages" action, for simplified command-line.

   Options for the 'distfiles' action
       -f, --fetch-restricted        protect fetch-restricted files (--destructive only)

       -s, --size-limit=<size>  don't delete disfiles bigger than <size>
              <size> is a size specification: "10M" is "ten megabytes", "200K" is "two hundreds kilobytes", etc.
              Units are: G, M, K and B.

   Options for the 'packages' action
       There is no specific option for this action.

EXCLUSION FILES
       Exclusions files are lists of packages names or categories you want to protect in particular.  This may be use-
       ful to protect more binary packages for some system related packages for instance.  Syntax is the following:

       o      blank lines and lines starting with a "#" (comments) are ignored.

       o      only one entry per line is allowed.

       o      if a line contains a category name, like "sys-apps", then all packages from this category will  be  pro-
              tected.   "sys-apps/*"  is  also allowed for aesthetic reasons, but that does NOT mean that wildcard are
              supported in any way for any other usage.

       o      if a line contains a package name ("app-shells/bash"), then this package will be  protected.   Versioned
              atoms  like  ">=app-shells/bash-3"  are  NOT  supported.  Also, the full package name (with category) is
              mandatory.

       o      if a line contains a package name with an exclamation mark in  front  ("!sys-apps/portage"),  then  this
              package will be excluded from protection.  This is only useful if the category itself was protected.

       o      for  distfiles  protection, a line can also a filename to protect. This is useful if you have there some
              files which are not registered by the ebuilds, like OpenOffice.org i18n files ("helpcontent_33_unix.tgz"
              for instance).

       By  default,  if  it  exists, /etc/eclean/packages.exclude (resp. distfiles.exclude) will be use when action is
       "packages" (resp. "distfiles").  This can be overide with the --exclude-file option.

EXAMPLES
       Clean distfiles only, with per file confirmation prompt:
       # eclean -i distfiles

       Check which binary packages could be removed, with a no-color display:
       # eclean -Cp packages

       Clean binary packages of uninstalled packages, but keep all versions of installed ones:
       # eclean-pkg -d -n

       Clean all distfiles except for installed packages (exact version), those which are less  than  one  month  old,
       bigger than 50MB, or fetch-restricted:
       # eclean-dist -d -t1m -s50M -f

       From a crontab, silently clean packages in the safest mode, and then distfiles in destructive mode but protect-
       ing files less than a week old, every sunday at 1am:
       0 1 * * sun   eclean -C -q packages ; eclean -C -q -d -t1w distfiles

SEE ALSO
       The Gentoo forum thread that gave birth to eclean:
              http://forums.gentoo.org/viewtopic.php?t=3011

       The bug report requesting eclean inclusion in gentoolkit:
              http://bugs.gentoo.org/show_bug.cgi?id=33877

       Yacleaner, one of the other similar tools:
              http://blog.tacvbo.net/data/files/yacleaner/

AUTHORS
       Thomas de Grenier de Latour (tgl) <degrenier@easyconnect.fr>
回复 支持 反对

使用道具 举报

发表于 2006-2-2 06:52:11 | 显示全部楼层
谢谢fei版主提供这个讯息, 我有时间来看看
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

快速回复 返回顶部 返回列表