⚠️ Remove settings param from rules match, get_new_command and side_effect

This commit is contained in:
nvbn
2015-09-07 13:00:29 +03:00
parent 382eb8b86c
commit df4d2cc88d
154 changed files with 535 additions and 465 deletions
+2 -2
View File
@@ -24,7 +24,7 @@ def _get_similar_formula(formula_name):
return get_closest(formula_name, _get_formulas(), 1, 0.85)
def match(command, settings):
def match(command):
is_proper_command = ('brew install' in command.script and
'No available formula' in command.stderr)
@@ -35,7 +35,7 @@ def match(command, settings):
return False
def get_new_command(command, settings):
def get_new_command(command):
not_exist_formula = re.findall(r'Error: No available formula for ([a-z]+)',
command.stderr)[0]
exist_formula = _get_similar_formula(not_exist_formula)