mirror of
https://github.com/nvbn/thefuck.git
synced 2025-03-20 09:39:01 +00:00
fix small errors to get it to compile with appveyor
This commit is contained in:
parent
6227299d07
commit
628bc8dddf
@ -7,12 +7,13 @@ def _get_executable(script_part):
|
|||||||
if script_part.startswith(executable):
|
if script_part.startswith(executable):
|
||||||
if executable.startswith("apt"):
|
if executable.startswith("apt"):
|
||||||
if script_part.startswith("apt-get"):
|
if script_part.startswith("apt-get"):
|
||||||
if len(script_part)> len("apt-get"):
|
if len(script_part) > len("apt-get"):
|
||||||
return "apt-get"
|
return "apt-get"
|
||||||
else:
|
else:
|
||||||
return
|
return
|
||||||
return executable
|
return executable
|
||||||
|
|
||||||
|
|
||||||
def match(command):
|
def match(command):
|
||||||
return (not command.script_parts[0] in get_all_executables()
|
return (not command.script_parts[0] in get_all_executables()
|
||||||
and _get_executable(command.script_parts[0]))
|
and _get_executable(command.script_parts[0]))
|
||||||
@ -24,11 +25,3 @@ def get_new_command(command):
|
|||||||
|
|
||||||
|
|
||||||
priority = 4000
|
priority = 4000
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user