From e54ff39b5928186c828d6d5201590abf9f86e057 Mon Sep 17 00:00:00 2001 From: silambarasa Date: Sun, 19 Nov 2023 16:57:40 +0530 Subject: [PATCH] new_rule_created --- thefuck/rules/install_packages.py | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100644 thefuck/rules/install_packages.py diff --git a/thefuck/rules/install_packages.py b/thefuck/rules/install_packages.py new file mode 100644 index 0000000..85fafc7 --- /dev/null +++ b/thefuck/rules/install_packages.py @@ -0,0 +1,9 @@ +from thefuck.utils import for_app + +@for_app('apt-get') +def match(command): + return 'Do you want to continue?' in command.output + +def get_new_command(command): + new_command = command.script.replace('apt-get', 'apt-get -y') + return new_command \ No newline at end of file