Dotfiles for my tiling window manager + terminal workflow.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

17 lines
639 B

5 years ago
  1. function server-pages
  2. set sites kevin-mok.com git.kevin-mok.com cal.khkm.tk mnpd.gq/kbg pste.gq smol.gq twem.tk
  3. set titles "Kevin Mok" "Kevin Mok's Gitea" "Baïkal server" "kbg" "hastebin" "Kevin's URL Shortener" "Twitch Emote Links"
  4. # set sites twem.tk
  5. # set titles "Twitch Emote Links"
  6. for i in (seq (count $sites))
  7. set title (wget -qO- "$sites[$i]" | perl -l -0777 -ne 'print $1 if /<title.*?>\s*(.*?)\s*<\/title/si' | recode html)
  8. if test $title = $titles[$i]
  9. set symbol "✓"
  10. else
  11. set symbol "✗"
  12. end
  13. printf "[$symbol] $sites[$i]\n"
  14. end
  15. end