Gentoolkit/zh-cn

Gentoolkit是一套简化Gentoo系统管理的工具，本文档介绍了Gentoolkit中的一些工具的基础知识.

Gentoolkit是什么?
Gentoo是一款独特的发行版，它呈现了一些对于其他发行版根本不存在的复杂性. 由于Gentoo开发人员和贡献者发现了其中的一些复杂性，他们还编写了一些工具来帮助用户和管理员解决这些问题. 许多工具已经贡献给Gentoo项目，并包含在包中.

Gentoolkit包含大量有用的工具，可帮助用户管理包并跟踪系统中发生的情况. 大多数用户（特别是经常更新系统的用户）将从安装Gentoolkit中受益.

安装
与大多数其他Gentoo软件包一样，安装就像一样简单：

查找文档
程序可能具有的任何文档（手册页除外）都存储在中.

euse
是一个在各个地方查看，设置和取消设置USE标记的工具. 有关USE标志的更多信息，请参阅USE标志. 有关完整帮助和所有选项，请参阅.

查看，设置和取消设置USE标志
命令读取当前活动的USE标志并显示它们.

类似地，命令用于查看活动的全局USE标志. 命令对活动的本地USE标志执行相同的操作. 和 是euse的子选项，需要在它们之前使用一个选项（如 ）才能正常运行.

is able to set or unset USE flags. The commands used for this are (enable a flag) and  (disable a flag).

Enabling a USE flag:

The file looks like so after the command was ran:

Disabling a USE flag:

Again, the file after the command:

revdep-rebuild
This tool is Gentoo's Reverse Dependency rebuilder. It will scan the installed ebuilds to find packages that have become broken as a result of an upgrade of a package they depend on. It can emerge those packages for users automatically but it can also happen that a given package does not work with the currently installed dependencies, in which case you should upgrade the broken package to a more recent version. will pass flags to which lets you use the   flag to see what is going to be emerged again before going any further.

To rebuild some packages run without the   flag and the listed packages will be emerged again.

glsa-check
glsa-check is mainly a test tool that keeps track of the various GLSA's (Gentoo Linux Security Advisory) and will eventually be integrated into and.

eread
is a simple utility to display elog files produced by Portage since version 2.1. The saving of elog files can be enabled by setting a couple of variables in :

Once elog has been set up to satisfaction, run to view the log files.

Select a number and the file will be displayed using the paging program specified in the PAGER environment variable. If PAGER is not set, it will use. The PAGER environmental variable can be set using (module  ).

After displaying the elog item, you will be prompted if you want to delete the file.

eclean
is a tool to remove old source files and old binary packages from the system.

When building and installing packages, the source files are downloaded and preserved in DISTDIR, usually. This can accumulate several gigabytes of material over time if it is not cleaned periodically. Users should run to clean source files from DISTDIR.

It is possible to create archives of installed packages by using or. These archived packages are kept in PKGDIR, usually. When they are no longer needed, or if they are too old, can be ran to remove them from PKGDIR. It is a good way to ensure that any binary packages on the system are only the latest versions.

For more information on and tips on maintaining a cruft-free system, please read  or check the eclean article.