Sleep a bit before starting aggietime auth on work machine, in watch aggietime dont remove the socket

This commit is contained in:
Lizzy Hunt 2023-02-28 12:41:07 -07:00
parent a7b1db72e6
commit f862b976dd
No known key found for this signature in database
GPG Key ID: 8AC6A4B840C0EC49
2 changed files with 6 additions and 5 deletions

View File

@ -21,5 +21,5 @@
(setq *mouse-focus-policy* :sloppy) (setq *mouse-focus-policy* :sloppy)
(when (is-work-machine) (when (is-work-machine)
(run-shell-command "~/scripts/watch_aggietimed.sh")) (run-shell-command "sleep 3 && . ~/scripts/watch_aggietimed.sh"))
(run-shell-command "dunst") (run-shell-command "dunst")

View File

@ -1,16 +1,17 @@
#!/bin/bash #!/bin/sh
socket=/tmp/aggietimed.sock socket=/tmp/aggietimed.sock
env_file=/home/lizzy/work/simple_scripts/aggietime_cli/.env
export $(cat $env_file | xargs)
while true while true
do do
aggietimed -d --socket-path $socket aggietimed -d -s $socket
if [ $? -eq 0 ] if [ $? -eq 0 ]
then then
break break
else else
rm $socket
sleep 1 sleep 1
fi fi
done done