Gentoo Archives: gentoo-commits

From: Zac Medico <zmedico@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] proj/portage:master commit in: bin/
Date: Sat, 29 Oct 2011 03:26:40
Message-Id: c7a9678751251c027a3b2072962be49865c2c6f2.zmedico@gentoo
1 commit: c7a9678751251c027a3b2072962be49865c2c6f2
2 Author: Zac Medico <zmedico <AT> gentoo <DOT> org>
3 AuthorDate: Sat Oct 29 03:26:18 2011 +0000
4 Commit: Zac Medico <zmedico <AT> gentoo <DOT> org>
5 CommitDate: Sat Oct 29 03:26:18 2011 +0000
6 URL: http://git.overlays.gentoo.org/gitweb/?p=proj/portage.git;a=commit;h=c7a96787
7
8 portageq: refer to <eroot> instead of <root>
9
10 Since commit a715b65f7bd36409c1283e6911265d1f4405ab7a, portageq takes
11 EROOT as the first argument of commands that require a root argument.
12 So, update the docs to refer to <eroot> instead of <root>.
13
14 ---
15 bin/portageq | 50 +++++++++++++++++++++++++-------------------------
16 1 files changed, 25 insertions(+), 25 deletions(-)
17
18 diff --git a/bin/portageq b/bin/portageq
19 index 66f6509..cee343f 100755
20 --- a/bin/portageq
21 +++ b/bin/portageq
22 @@ -79,7 +79,7 @@ def eval_atom_use(atom):
23 #
24
25 def has_version(argv):
26 - """<root> <category/package>
27 + """<eroot> <category/package>
28 Return code 0 if it's available, 1 otherwise.
29 """
30 if (len(argv) < 2):
31 @@ -126,7 +126,7 @@ has_version.uses_root = True
32
33
34 def best_version(argv):
35 - """<root> <category/package>
36 + """<eroot> <category/package>
37 Returns category/package-version (without .ebuild).
38 """
39 if (len(argv) < 2):
40 @@ -166,7 +166,7 @@ best_version.uses_root = True
41
42
43 def mass_best_version(argv):
44 - """<root> [<category/package>]+
45 + """<eroot> [<category/package>]+
46 Returns category/package-version (without .ebuild).
47 """
48 if (len(argv) < 2):
49 @@ -204,7 +204,7 @@ def metadata(argv):
50 sys.exit(1)
51
52 metadata.__doc__ = """
53 -<root> <pkgtype> <category/package> [<key>]+
54 +<eroot> <pkgtype> <category/package> [<key>]+
55 Returns metadata values for the specified package.
56 Available keys: %s
57 """ % ','.join(sorted(x for x in portage.auxdbkeys \
58 @@ -213,10 +213,10 @@ if not x.startswith('UNUSED_')))
59 metadata.uses_root = True
60
61 def contents(argv):
62 - """<root> <category/package>
63 + """<eroot> <category/package>
64 List the files that are installed for a given package, with
65 one file listed on each line. All file names will begin with
66 - <root>.
67 + <eroot>.
68 """
69 if len(argv) != 2:
70 print("ERROR: expected 2 parameters, got %d!" % len(argv))
71 @@ -235,11 +235,11 @@ def contents(argv):
72 contents.uses_root = True
73
74 def owners(argv):
75 - """<root> [<filename>]+
76 + """<eroot> [<filename>]+
77 Given a list of files, print the packages that own the files and which
78 files belong to each package. Files owned by a package are listed on
79 the lines below it, indented by a single tab character (\\t). All file
80 - paths must either start with <root> or be a basename alone.
81 + paths must either start with <eroot> or be a basename alone.
82 Returns 1 if no owners could be found, and 0 otherwise.
83 """
84 if len(argv) < 2:
85 @@ -272,7 +272,7 @@ def owners(argv):
86 f = os.path.join(cwd, f)
87 f = portage.normalize_path(f)
88 if not is_basename and not f.startswith(eroot):
89 - sys.stderr.write("ERROR: file paths must begin with <root>!\n")
90 + sys.stderr.write("ERROR: file paths must begin with <eroot>!\n")
91 sys.stderr.flush()
92 return 2
93 if is_basename:
94 @@ -316,9 +316,9 @@ def owners(argv):
95 owners.uses_root = True
96
97 def is_protected(argv):
98 - """<root> <filename>
99 + """<eroot> <filename>
100 Given a single filename, return code 0 if it's protected, 1 otherwise.
101 - The filename must begin with <root>.
102 + The filename must begin with <eroot>.
103 """
104 if len(argv) != 2:
105 sys.stderr.write("ERROR: expected 2 parameters, got %d!\n" % len(argv))
106 @@ -344,7 +344,7 @@ def is_protected(argv):
107 f = portage.normalize_path(f)
108
109 if not f.startswith(root):
110 - err.write("ERROR: file paths must begin with <root>!\n")
111 + err.write("ERROR: file paths must begin with <eroot>!\n")
112 err.flush()
113 return 2
114
115 @@ -363,9 +363,9 @@ def is_protected(argv):
116 is_protected.uses_root = True
117
118 def filter_protected(argv):
119 - """<root>
120 + """<eroot>
121 Read filenames from stdin and write them to stdout if they are protected.
122 - All filenames are delimited by \\n and must begin with <root>.
123 + All filenames are delimited by \\n and must begin with <eroot>.
124 """
125 if len(argv) != 1:
126 sys.stderr.write("ERROR: expected 1 parameter, got %d!\n" % len(argv))
127 @@ -405,7 +405,7 @@ def filter_protected(argv):
128 f = portage.normalize_path(f)
129
130 if not f.startswith(root):
131 - err.write("ERROR: file paths must begin with <root>!\n")
132 + err.write("ERROR: file paths must begin with <eroot>!\n")
133 err.flush()
134 errors += 1
135 continue
136 @@ -423,7 +423,7 @@ def filter_protected(argv):
137 filter_protected.uses_root = True
138
139 def best_visible(argv):
140 - """<root> [pkgtype] <atom>
141 + """<eroot> [pkgtype] <atom>
142 Returns category/package-version (without .ebuild).
143 The pkgtype argument defaults to "ebuild" if unspecified,
144 otherwise it must be one of ebuild, binary, or installed.
145 @@ -503,7 +503,7 @@ best_visible.uses_root = True
146
147
148 def mass_best_visible(argv):
149 - """<root> [<category/package>]+
150 + """<eroot> [<category/package>]+
151 Returns category/package-version (without .ebuild).
152 """
153 if (len(argv) < 2):
154 @@ -519,7 +519,7 @@ mass_best_visible.uses_root = True
155
156
157 def all_best_visible(argv):
158 - """<root>
159 + """<eroot>
160 Returns all best_visible packages (without .ebuild).
161 """
162 if len(argv) < 1:
163 @@ -536,7 +536,7 @@ all_best_visible.uses_root = True
164
165
166 def match(argv):
167 - """<root> <atom>
168 + """<eroot> <atom>
169 Returns a \\n separated list of category/package-version.
170 When given an empty string, all installed packages will
171 be listed.
172 @@ -586,7 +586,7 @@ def match(argv):
173 match.uses_root = True
174
175 def expand_virtual(argv):
176 - """<root> <atom>
177 + """<eroot> <atom>
178 Returns a \\n separated list of atoms expanded from a
179 given virtual atom (GLEP 37 virtuals only),
180 excluding blocker atoms. Satisfied
181 @@ -700,8 +700,8 @@ def envvar(argv):
182 print(portage.settings[arg])
183
184 def get_repos(argv):
185 - """<root>
186 - Returns all repos with names (repo_name file) argv[0] = $ROOT
187 + """<eroot>
188 + Returns all repos with names (repo_name file) argv[0] = $EROOT
189 """
190 if len(argv) < 1:
191 print("ERROR: insufficient parameters!")
192 @@ -709,8 +709,8 @@ def get_repos(argv):
193 print(" ".join(portage.db[argv[0]]["porttree"].dbapi.getRepositories()))
194
195 def get_repo_path(argv):
196 - """<root> <repo_id>+
197 - Returns the path to the repo named argv[1], argv[0] = $ROOT
198 + """<eroot> <repo_id>+
199 + Returns the path to the repo named argv[1], argv[0] = $EROOT
200 """
201 if len(argv) < 2:
202 print("ERROR: insufficient parameters!")
203 @@ -722,7 +722,7 @@ def get_repo_path(argv):
204 print(path)
205
206 def list_preserved_libs(argv):
207 - """<root>
208 + """<eroot>
209 Print a list of libraries preserved during a package update in the form
210 package: path. Returns 1 if no preserved libraries could be found,
211 0 otherwise.