bash else if
if [ -d $directory ]; then
echo "Directory exists"
elif [ -d $directory2 ]; then
echo "Directory2 exists"
else
echo "Directory does not exists"
fi
if [ -d $directory ]; then
echo "Directory exists"
elif [ -d $directory2 ]; then
echo "Directory2 exists"
else
echo "Directory does not exists"
fi
Comments