1 |
commit: 2b4abfec2576c6f50d23dd331827c17aace315b3 |
2 |
Author: Alexander Berntsen <alexander <AT> plaimi <DOT> net> |
3 |
AuthorDate: Tue Jul 30 20:15:34 2013 +0000 |
4 |
Commit: Zac Medico <zmedico <AT> gentoo <DOT> org> |
5 |
CommitDate: Tue Jul 30 22:36:42 2013 +0000 |
6 |
URL: http://git.overlays.gentoo.org/gitweb/?p=proj/portage.git;a=commit;h=2b4abfec |
7 |
|
8 |
bin/fixpackages: Add -h, fixes bug #394773 |
9 |
|
10 |
--- |
11 |
bin/fixpackages | 8 ++++++++ |
12 |
pym/portage/util/_argparse.py | 1 + |
13 |
2 files changed, 9 insertions(+) |
14 |
|
15 |
diff --git a/bin/fixpackages b/bin/fixpackages |
16 |
index e224b62..e29d6ee 100755 |
17 |
--- a/bin/fixpackages |
18 |
+++ b/bin/fixpackages |
19 |
@@ -14,12 +14,20 @@ import portage |
20 |
portage._internal_caller = True |
21 |
from portage import os |
22 |
from portage.output import EOutput |
23 |
+from portage.util._argparse import ArgumentParser |
24 |
from textwrap import wrap |
25 |
from portage._global_updates import _global_updates |
26 |
mysettings = portage.settings |
27 |
mytrees = portage.db |
28 |
mtimedb = portage.mtimedb |
29 |
|
30 |
+description = """The fixpackages program performs package move updates on |
31 |
+ configuration files, installed packages, and binary packages.""" |
32 |
+description = " ".join(description.split()) |
33 |
+ |
34 |
+parser = ArgumentParser(description=description) |
35 |
+parser.parse_args() |
36 |
+ |
37 |
if mysettings['ROOT'] != "/": |
38 |
out = EOutput() |
39 |
msg = "The fixpackages program is not intended for use with " + \ |
40 |
|
41 |
diff --git a/pym/portage/util/_argparse.py b/pym/portage/util/_argparse.py |
42 |
index 5e6a9ba..4227f4c 100644 |
43 |
--- a/pym/portage/util/_argparse.py |
44 |
+++ b/pym/portage/util/_argparse.py |
45 |
@@ -17,3 +17,4 @@ except ImportError: |
46 |
parser = OptionParser(**kwargs) |
47 |
self.add_argument = parser.add_option |
48 |
self.parse_known_args = parser.parse_args |
49 |
+ self.parse_args = parser.parse_args |