From 713d6a801b17018cce51bb4a8e044b29c85ea42b Mon Sep 17 00:00:00 2001 From: aminnairi <18418459+aminnairi@users.noreply.github.com> Date: Sun, 9 Nov 2025 19:06:31 +0100 Subject: [PATCH] initial commit --- sources/fish/functions/fuck.fish | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100644 sources/fish/functions/fuck.fish diff --git a/sources/fish/functions/fuck.fish b/sources/fish/functions/fuck.fish new file mode 100644 index 0000000..3d6cceb --- /dev/null +++ b/sources/fish/functions/fuck.fish @@ -0,0 +1,9 @@ +function fuck -d "Correct your previous console command" + set -l fucked_up_command $history[1] + env TF_SHELL=fish TF_ALIAS=fuck PYTHONIOENCODING=utf-8 thefuck $fucked_up_command THEFUCK_ARGUMENT_PLACEHOLDER $argv | read -l unfucked_command + if [ "$unfucked_command" != "" ] + eval $unfucked_command + builtin history delete --exact --case-sensitive -- $fucked_up_command + builtin history merge + end +end