Update install-tr-control.sh

Please either use find to search only in common directories like i propose or use "-mount" parameter to a find command which would prevent scanning mounted external drives. In my case current version takes more than 30 minutes to complete scan due to external drive mount points..
This commit is contained in:
slrslr 2020-11-15 12:21:42 +00:00 committed by GitHub
parent ba0cc207cc
commit 01d170e1ab
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -160,7 +160,7 @@ findWebFolder() {
showLog "$ROOT_FOLDER/web $MSG_AVAILABLE."
else
showLog "$MSG_THE_SPECIFIED_DIRECTORY_DOES_NOT_EXIST"
ROOT_FOLDER=`find / -name 'web' -type d 2>/dev/null| grep 'transmission/web' | sed 's/\/web$//g'`
ROOT_FOLDER=`find /usr /etc /home /root -name 'web' -type d 2>/dev/null| grep 'transmission/web' | sed 's/\/web$//g'`
if [ -d "$ROOT_FOLDER/web" ]; then
WEB_FOLDER="$ROOT_FOLDER/web"