mirror of https://github.com/pypa/pip
Stop trying to lowercase commands, it wasn't working anyway
This commit is contained in:
parent
9539ce21cb
commit
000a59d8ee
|
@ -149,11 +149,11 @@ def parseopts(args):
|
|||
sys.exit()
|
||||
|
||||
# the subcommand name
|
||||
cmd_name = args_else[0].lower()
|
||||
cmd_name = args_else[0]
|
||||
|
||||
# all the args without the subcommand
|
||||
cmd_args = args[:]
|
||||
cmd_args.remove(args_else[0].lower())
|
||||
cmd_args.remove(args_else[0])
|
||||
|
||||
if cmd_name not in commands:
|
||||
guess = get_similar_commands(cmd_name)
|
||||
|
|
|
@ -67,14 +67,14 @@ def get_similar_commands(name):
|
|||
"""Command name auto-correct."""
|
||||
from difflib import get_close_matches
|
||||
|
||||
name = name.lower()
|
||||
|
||||
close_commands = get_close_matches(name, commands.keys())
|
||||
|
||||
if close_commands:
|
||||
guess = close_commands[0]
|
||||
return close_commands[0]
|
||||
else:
|
||||
guess = False
|
||||
|
||||
return guess
|
||||
return False
|
||||
|
||||
|
||||
def _sort_commands(cmddict, order):
|
||||
|
|
Loading…
Reference in New Issue