From e534b1760f06109ca7b51a18fc1209f758b32415 Mon Sep 17 00:00:00 2001 From: Oleg Broytman Date: Wed, 5 Jun 2024 19:45:16 +0300 Subject: [PATCH] Feat(.mc/menu): Make `zip` preserve symlinks --- .mc/menu | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.mc/menu b/.mc/menu index c2198c8..f5e1b68 100644 --- a/.mc/menu +++ b/.mc/menu @@ -311,7 +311,7 @@ z Compress the current subdirectory to zip echo -n "Name of the distribution file (without extension) [$Pwd]: " read zip if [ "$zip"x = x ]; then zip="$Pwd"; fi - cd .. && zip -r9 "$zip".zip "$Pwd" && + cd .. && zip -ry9 "$zip".zip "$Pwd" && echo ../"$zip".zip created. + t d & f ^\.\.$ @@ -358,7 +358,7 @@ z xz the file + ! f \.(z|Z|bz2|gz|lz|lzma)|(tbz2|tgz|tz|zip|ZIP|rar|RAR|xz|7z)$ & t lr z zip the file/directory - exec zip -r9 %f.zip %f + exec zip -ry9 %f.zip %f + ! f \.(z|Z|bz2|gz|lz|lzma)|(tbz2|tgz|tz|zip|ZIP|rar|RAR|xz|7z)$ & t lr y zip the file/directory recoding filename(s) @@ -367,7 +367,7 @@ y zip the file/directory recoding filename(s) + t t Z zip selected files/directories ZIP=%{Enter zip name} - exec zip -r9 "$ZIP" %s + exec zip -ry9 "$ZIP" %s + t t Y zip selected files/directories recoding filenames -- 2.39.5