Advertisement
metalx1000

Temperature Log BASH Script

Mar 22nd, 2020
722
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 1.58 KB | None | 0 0
  1. #!/bin/bash
  2. ######################################################################
  3. #Copyright (C) 2020  Kris Occhipinti
  4. #https://filmsbykris.com
  5.  
  6. #This program is free software: you can redistribute it and/or modify
  7. #it under the terms of the GNU General Public License as published by
  8. #the Free Software Foundation, either version 3 of the License, or
  9. #(at your option) any later version.
  10.  
  11. #This program is distributed in the hope that it will be useful,
  12. #but WITHOUT ANY WARRANTY; without even the implied warranty of
  13. #MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  14. #GNU General Public License for more details.
  15.  
  16. #You should have received a copy of the GNU General Public License
  17. #along with this program.  If not, see <http://www.gnu.org/licenses/>.
  18. ######################################################################
  19.  
  20. people=$(wget -qO- "https://filmsbykris.com/scripts/2020/employee.lst")
  21. url="https://filmsbykris.com/scripts/2020/temp_log/submit.php"
  22.  
  23. while [ "$exit" != "Exit" ]
  24. do
  25.   employee="$(echo "$people"|fzf --prompt "Employee: "|cut -d\| -f1)"
  26.  
  27.   temp="$(for i in $(seq 90 0.1 110);do echo "$i";done|fzf --prompt "Temperature: ")"
  28.  
  29.   cough="$(echo -e "Yes\nNo"|fzf --prompt "Cough: ")"
  30.   throat="$(echo -e "Yes\nNo"|fzf --prompt "Sore Throat: ")"
  31.   nose="$(echo -e "Yes\nNo"|fzf --prompt "Runny Noise: ")"
  32.  
  33.   wget -qO- "$url?employee=$employee&temp=$temp&cough=$cough&throat=$throat&nose=$nose"
  34.   sleep 2
  35.   echo "================================================="
  36.  
  37.   exit="$(echo -e "Enter another employee\nExit"|fzf)"
  38. done
  39.  
  40. echo "Goodbye"
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement