Make portageq exit successfully for -h or --help.
authorZac Medico <zmedico@gentoo.org>
Wed, 20 Sep 2006 03:09:44 +0000 (03:09 -0000)
committerZac Medico <zmedico@gentoo.org>
Wed, 20 Sep 2006 03:09:44 +0000 (03:09 -0000)
svn path=/main/trunk/; revision=4484

bin/portageq

index 4166425ec67e000358a4ac7c52f8c355a46e0651..46b0903ddab3c9c169163ce5446e0f85f620aaf5 100755 (executable)
@@ -319,7 +319,10 @@ def usage(argv):
                print "\nRun portageq with --help for info"
 
 def main():
-       if (len(sys.argv) < 2) or ("-h" in sys.argv or "--help" in sys.argv):
+       if "-h" in sys.argv or "--help" in sys.argv:
+               usage(sys.argv)
+               sys.exit(os.EX_OK)
+       elif len(sys.argv) < 2:
                usage(sys.argv)
                sys.exit(os.EX_USAGE)