projects
/
feisty_meow.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
935f2f9
)
new script to find read only files
author
Chris Koeritz
<fred@gruntose.com>
Tue, 29 Jan 2019 05:41:06 +0000
(
00:41
-0500)
committer
Chris Koeritz
<fred@gruntose.com>
Tue, 29 Jan 2019 05:41:06 +0000
(
00:41
-0500)
very efficient.
scripts/files/find_readonly.sh
[new file with mode: 0644]
patch
|
blob
diff --git a/scripts/files/find_readonly.sh
b/scripts/files/find_readonly.sh
new file mode 100644
(file)
index 0000000..
833dd17
--- /dev/null
+++ b/
scripts/files/find_readonly.sh
@@ -0,0
+1,9
@@
+#!/bin/bash
+
+# locates read only files in the directories specified.
+# this is a much simpler and more efficient command than some i've seen
+# floating about; it gets the find command to do all the heavy lifting
+# and doesn't try to build impossibly large command lines.
+
+find "${@}" -follow -type f -perm -u+r -a ! -perm -u+w
+