simplify. Not search for target folder, but ask user to enter target folder

This commit is contained in:
Luk Lu
2023-07-09 14:34:25 +08:00
parent 2eda3bd469
commit 4b808e2bde
10 changed files with 30 additions and 198 deletions

View File

@@ -1,26 +1,8 @@
#!/bin/bash
FONPATH1=/faronear
FONPATH2=~/faronear.mycode
FONPATH3=~/faronear
FONPATH4=/mnt/d/faronear
echo "*** Testing [$1] [$FONPATH1] [$FONPATH2] [$FONPATH3] [$FONPATH4]"
if [ "$1" ]
if [ -d "$1" ]
then
FONPATH=$1
elif [ -d $FONPATH1 ]
then
FONPATH=$FONPATH1
elif [ -d $FONPATH2 ]
then
FONPATH=$FONPATH2
elif [ -d $FONPATH3 ]
then
FONPATH=$FONPATH3
elif [ -d $FONPATH4 ]
then
FONPATH=$FONPATH4
else
echo "××× All testing path failed."
echo ""