Merge branch 'main' of github.com:frrobert2/StationNotifier into main
[stationnotifier] / notificatorossl
index bcd142b92e1927ff9b5cdceb83bcc5e0c64df61b..5ade715bab70900bb851d0422bf7e53f689c5a03 100755 (executable)
@@ -2,9 +2,10 @@
 # notifitcatorossl is a fork of https://github.com/ThatsRedacted/StationNotifier
 # This program uses openssl rather than curl to connect to a gemini site`
 
-key='/home/frrobert/.config/amfora/7debbb3fae40dbe77746aa465300febaec5abb778faa8a550f8e5924f0977983.key'
-cert='/home/frrobert/.config/amfora/7debbb3fae40dbe77746aa465300febaec5abb778faa8a550f8e5924f0977983.crt'
+key=''
+cert=''
 connectto=30
+howoften=
 
 tmpfile=$(mktemp /tmp/not.XXXXXX)
                 url="gemini://station.martinrue.com/frrobert"
@@ -36,12 +37,21 @@ do
     if [[ $notifications -gt $lasttime ]]; then
         echo -en "\007"
         echo "You have new notifications!"
-        read -p "Press enter to continue or amfora to go to notifications" answer
+        read -p "Press enter to continue, or either type amfora or lagrange to go to notifications" answer
        case $answer in
-               amfora) $(amfora gemini://station.martinrue.com/frrobert)
+               amfora)
+                      amfora $url
+                      clear
+                     ;;
+               lagrange)
+                       lagrange $url
+                       clear
+                       ;;
+               *)
+                       clear
                        ;;
        esac
-
+echo "waiting for new notifications"
         lasttime=$notifications
         unset my_array
     fi