From df78c2491d6591d01542fa37e813ee47c297a3f2 Mon Sep 17 00:00:00 2001 From: Azalea Gui <22280294+hykilpikonna@users.noreply.github.com> Date: Wed, 6 Nov 2024 11:50:33 -0500 Subject: [PATCH] [-] Block 7z d :(((( --- scripts/zshrc.sh | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/scripts/zshrc.sh b/scripts/zshrc.sh index efd4dc3..0f74418 100755 --- a/scripts/zshrc.sh +++ b/scripts/zshrc.sh @@ -193,6 +193,15 @@ gradle() { fi } +# Block the 7z d command becuase it's dangerous +7z() { + if [[ "$1" == "d" ]]; then + echo "7z d is blocked. It doesn't stand for decompress, it stands for delete." + else + command 7z "$@" + fi +} + # Unix permissions reset (Dangerous! This will make executable files no longer executable) reset-permissions-dangerous() { sudo find . -type d -exec chmod 755 {} \;