blob: 38c486b0a2a1f2f0deafd7d1e5210906ae62a733 [file] [log] [blame]
Nick Coghlan60f08c82013-11-30 17:45:09 +10001"""Basic pip uninstallation support, helper for the Windows uninstaller"""
2
3import argparse
4import ensurepip
5
6
7def main():
8 parser = argparse.ArgumentParser(prog="python -m ensurepip._uninstall")
9 parser.add_argument(
10 "--version",
11 action="version",
12 version="pip {}".format(ensurepip.version()),
13 help="Show the version of pip this will attempt to uninstall.",
14 )
15 parser.add_argument(
16 "-v", "--verbose",
17 action="count",
18 default=0,
19 dest="verbosity",
20 help=("Give more output. Option is additive, and can be used up to 3 "
21 "times."),
22 )
23
24 args = parser.parse_args()
25
26 ensurepip._uninstall(verbosity=args.verbosity)
27
28
29if __name__ == "__main__":
30 main()