1
0
mirror of https://github.com/nvbn/thefuck.git synced 2025-01-18 12:06:04 +00:00

Fixed incorrect ordering of for_app and sudo_support causing apt_invalid_operation and dnf_no_such_command rules to fail (#861)

This commit is contained in:
Chris De Pasquale 2018-12-11 11:01:17 +11:00 committed by Vladimir Iakovlev
parent d86dd5f179
commit 7bc619385b
2 changed files with 2 additions and 2 deletions

View File

@ -6,8 +6,8 @@ from thefuck.utils import for_app, eager, replace_command
enabled_by_default = apt_available
@for_app('apt', 'apt-get', 'apt-cache')
@sudo_support
@for_app('apt', 'apt-get', 'apt-cache')
def match(command):
return 'E: Invalid operation' in command.output

View File

@ -8,8 +8,8 @@ from thefuck.specific.dnf import dnf_available
regex = re.compile(r'No such command: (.*)\.')
@for_app('dnf')
@sudo_support
@for_app('dnf')
def match(command):
return 'no such command' in command.output.lower()