A ChatGPT based emulation of the therapist Doctor Kernel from the book "A digital Affair" by Neora Shem Shaul
Nevar pievienot vairāk kā 25 tēmas Tēmai ir jāsākas ar burtu vai ciparu, tā var saturēt domu zīmes ('-') un var būt līdz 35 simboliem gara.

run.sh 507B

123456789101112131415
  1. #!/bin/sh
  2. . ./.env
  3. . venv/bin/activate
  4. while [ 1 ] ; do
  5. LOGFILE=log-$(date +%Y%m%d-%H%M%S).txt
  6. python doctor.py|tee logs/$LOGFILE
  7. # Only 3rd '>' counts. We should also skip '<Enter>' in the header ;)
  8. if [ $(grep -c '>' logs/$LOGFILE) -lt 3 ] ; then
  9. rm logs/$LOGFILE
  10. dialog --title "Session aborted" --msgbox "Hit <Enter> to continue..." 5 60
  11. else
  12. python genlogs.py
  13. dialog --title "Session saved" --msgbox "Session saved to file $LOGFILE" 5 60
  14. fi
  15. done