From b4a5907d01b80a3054c5270f82ec301729805c26 Mon Sep 17 00:00:00 2001 From: dece Date: Tue, 29 Mar 2022 15:03:11 +0200 Subject: [PATCH] un-ntfs --- un-ntfs.sh | 7 +++++++ 1 file changed, 7 insertions(+) create mode 100755 un-ntfs.sh diff --git a/un-ntfs.sh b/un-ntfs.sh new file mode 100755 index 0000000..2eb8f98 --- /dev/null +++ b/un-ntfs.sh @@ -0,0 +1,7 @@ +#!/bin/bash +# Brutally reset file permissions to sane defaults for files/folders that have +# been tainted by a poorly mounted NTFS drive (777). +pushd "$1" +fdfind -t f -x chmod 644 +fdfind -t d -x chmod 755 +popd