pi-build/conky/grid

22 wiersze
379 B
Bash

#!/bin/bash
#script get maidenhead from GPS for display in conky
#called by cronjob
#04FEB2021 KM4ACK
GRID=$($HOME/bin/conky/get-grid)
GRIDCH=$(echo $GRID | grep -i JJ00)
FILE=/run/user/$UID/gridinfo.txt
#check if GPS software installed
if ! hash gpsd>/dev/null; then
echo "GPSD-Err" > $FILE
exit 1
fi
if [ -z "$GRIDCH" ]
then
echo $GRID > $FILE
else
echo "NO GPS" > $FILE
fi