mirror of
https://github.com/nvbn/thefuck.git
synced 2025-03-20 09:39:01 +00:00
Check if any elements in command are slow commands rather than just the first term
This commit is contained in:
parent
817ce9c71d
commit
e412fc92c6
@ -54,7 +54,7 @@ def get_output(script, expanded):
|
|||||||
env.update(settings.env)
|
env.update(settings.env)
|
||||||
|
|
||||||
split_expand = shlex.split(expanded)
|
split_expand = shlex.split(expanded)
|
||||||
is_slow = split_expand[0] in settings.slow_commands if split_expand else False
|
is_slow = not set(split_expand).isdisjoint(settings.slow_commands) if split_expand else False
|
||||||
with logs.debug_time(u'Call: {}; with env: {}; is slow: {}'.format(
|
with logs.debug_time(u'Call: {}; with env: {}; is slow: {}'.format(
|
||||||
script, env, is_slow)):
|
script, env, is_slow)):
|
||||||
result = Popen(expanded, shell=True, stdin=PIPE,
|
result = Popen(expanded, shell=True, stdin=PIPE,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user