in \fB/usr/share/portage/config/sets.conf\fR. Note that a \fIset\fR
is generally used in conjunction with \fB\-\-update\fR. When used as
arguments to \fBemerge\fR sets have to be prefixed with \fB@\fR to be
-recognized.
+recognized. Use the \fB\-\-list\-sets\fR action to display a list of
+available package sets.
.TP
.BR atom
An \fIatom\fR describes bounds on a package that you wish to install.
information when submitting a bug report.\fR Expanded output can be obtained
with the \fI\-\-verbose\fR option.
.TP
+.BR \-\-list\-sets
+Displays a list of available package sets.
+.TP
.BR \-\-metadata
Transfers metadata cache from ${PORTDIR}/metadata/cache/ to
/var/cache/edb/dep/ as is normally done on the
print "Interrupted."
sys.exit(1)
-actions=[
+actions = frozenset([
"clean", "config", "depclean",
-"info", "metadata",
+"info", "list-sets", "metadata",
"prune", "regen", "search",
"sync", "unmerge",
-]
+])
options=[
"--ask", "--alphabetical",
"--buildpkg", "--buildpkgonly",
print colorize("BAD", "\n*** emerging by path is broken and may not always work!!!\n")
break
+ root_config = trees[settings["ROOT"]]["root_config"]
+ if myaction == "list-sets":
+ sys.stdout.write("".join("%s\n" % s for s in sorted(root_config.sets)))
+ sys.stdout.flush()
+ return os.EX_OK
+
# only expand sets for actions taking package arguments
oldargs = myfiles[:]
if myaction in ("clean", "config", "depclean", "info", "prune", "unmerge", None):
- root_config = trees[settings["ROOT"]]["root_config"]
setconfig = root_config.setconfig
# display errors that occured while loading the SetConfig instance
for e in setconfig.errors:
"not support '--pretend'.\n") % myaction)
return 1
- root_config = trees[settings["ROOT"]]["root_config"]
-
if "sync" == myaction:
return action_sync(settings, trees, mtimedb, myopts, myaction)
elif "metadata" == myaction:
print " [ "+green("--jobs") + " " + turquoise("JOBS")+" ] [ "+green("--keep-going")+" ] [ " + green("--load-average")+" " + turquoise("LOAD") + " ]"
print " [ "+green("--newuse")+" ] [ "+green("--noconfmem")+" ] [ "+green("--nospinner")+" ] [ "+green("--oneshot")+" ]"
print " [ "+green("--reinstall ")+turquoise("changed-use")+" ] [ " + green("--with-bdeps")+" < " + turquoise("y") + " | "+ turquoise("n")+" > ]"
- print bold("Actions:")+" [ "+green("--clean")+" | "+green("--depclean")+" | "+green("--prune")+" | "+green("--regen")+" | "+green("--search")+" | "+green("--unmerge")+" ]"
+ print bold("Actions:")+" [ "+green("--depclean")+" | "+green("--list-sets")+" | "+green("--search")+" | "+green("--sync")+" | "+green("--version")+" ]"
def help(myaction,myopts,havecolor=1):
# TODO: Implement a wrap() that accounts for console color escape codes.
print " make.{conf,globals,defaults} and the environment show up if"
print " run with the '--verbose' flag."
print
+ print " " + green("--list-sets")
+ paragraph = "Displays a list of available package sets."
+
+ for line in wrap(paragraph, desc_width):
+ print desc_indent + line
+ print
print " "+green("--metadata")
print " Transfers metadata cache from ${PORTDIR}/metadata/cache/ to"
print " /var/cache/edb/dep/ as is normally done on the tail end of an"