#N/A Add a new rule brew_update_formula

This commit is contained in:
Pablo Santiago Blum de Aguiar
2016-04-20 22:27:39 -03:00
parent 5ec4909d2f
commit 9d9820676a
3 changed files with 43 additions and 0 deletions
+12
View File
@@ -0,0 +1,12 @@
from thefuck.utils import for_app
@for_app('brew', at_least=2)
def match(command):
return ('update' in command.script
and "Error: This command updates brew itself" in command.stderr
and "Use 'brew upgrade <formula>'" in command.stderr)
def get_new_command(command):
return command.script.replace('update', 'upgrade')