5 args = ' '.join(sys.argv[1:])
6 if "--sort=" not in args:
9 pager = os.environ.get("PAGER", "more")
10 # if pager is 'less', option '-S' must be passed to it
12 less = os.environ.get("LESS") or ''
16 os.environ["LESS"] = less
17 os.system("ps %s | %s" % (args, pager))