if (len(argv) < 2):
print "ERROR: insufficient parameters!"
sys.exit(2)
+ if atom_validate_strict and not portage.isvalidatom(argv[1]):
+ portage.writemsg("ERROR: Invalid atom: '%s'\n" % argv[1],
+ noiselevel=-1)
+ return 2
try:
mylist=portage.db[argv[0]]["vartree"].dbapi.match(argv[1])
if mylist:
if (len(argv) < 2):
print "ERROR: insufficient parameters!"
sys.exit(2)
+ if atom_validate_strict and not portage.isvalidatom(argv[1]):
+ portage.writemsg("ERROR: Invalid atom: '%s'\n" % argv[1],
+ noiselevel=-1)
+ return 2
try:
mylist=portage.db[argv[0]]["vartree"].dbapi.match(argv[1])
print portage.best(mylist)
if (len(sys.argv) == 1):
print "\nRun portageq with --help for info"
+atom_validate_strict = "EBUILD_PHASE" in os.environ
+
def main():
if "-h" in sys.argv or "--help" in sys.argv:
usage(sys.argv)