Update ggo.sh

Major re-write to added error detection.