MCPcopy Create free account
hub / github.com/RT-Thread/env-windows / print_usage

Method print_usage

tools/python-3.11.9-amd64/Lib/optparse.py:1578–1588  ·  view source on GitHub ↗

print_usage(file : file = stdout) Print the usage message for the current program (self.usage) to 'file' (default stdout). Any occurrence of the string "%prog" in self.usage is replaced with the name of the current program (basename of sys.argv[0]). Does nothi

(self, file=None)

Source from the content-addressed store, hash-verified

1576 return ""
1577
1578 def print_usage(self, file=None):
1579 """print_usage(file : file = stdout)
1580
1581 Print the usage message for the current program (self.usage) to
1582 'file' (default stdout). Any occurrence of the string "%prog" in
1583 self.usage is replaced with the name of the current program
1584 (basename of sys.argv[0]). Does nothing if self.usage is empty
1585 or not defined.
1586 """
1587 if self.usage:
1588 print(self.get_usage(), file=file)
1589
1590 def get_version(self):
1591 if self.version:

Callers 5

mainFunction · 0.95
mainFunction · 0.95
errorMethod · 0.95
runMethod · 0.45
errorMethod · 0.45

Calls 2

get_usageMethod · 0.95
printFunction · 0.50

Tested by

no test coverage detected