#!/usr/bin/sh LAMPP='/opt/lampp/lampp' STATUS=$($LAMPP status 2> /dev/null) PROFTP=$(echo "$STATUS" | grep -i proftp | grep -io not > /dev/null && echo "down" || echo "up") if [ "$PROFTP" = "up" ]; then COLOUR="#00FF00" else COLOUR="#FF0000" fi echo "ProFTP" echo "" echo "$COLOUR"