|
From: | Chris Elvidge |
Subject: | Re: Speeding up a find and subsequent grep |
Date: | Mon, 21 Dec 2020 15:46:18 +0000 |
User-agent: | Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.2.1 Lightning/5.4 |
On 21/12/2020 12:55 pm, Greg Wooledge wrote:
On Sat, Dec 19, 2020 at 01:56:22PM +0000, Chris Elvidge wrote:I don't know if it will help but: make a executable script like this #!/bin/bash ## ./auto_chmod ## 750 is same as u=rwx,g=rx,o= echo "$1" file -b "$1" | grep -E "^PHP|^Python" && chmod -v 750 "$1" || chmod -v 640 "$1"https://mywiki.wooledge.org/BashPitfalls#pf22
Yes OK. -- Chris Elvidge England
[Prev in Thread] | Current Thread | [Next in Thread] |