Did you see the library of viz? https://github.com/attogram/bash-screensavers/blob/main/libr...
My favourite API: lov_die_with_honor()
  # This version is optimized for speed by:
  # 1. Using direct ANSI escape codes instead of forking `tput` for every update.A friend of mine fancied the following when making an infinite loop in C:
  #define MONEY 1
  #define POWER 1
  while (MONEY == POWER)
  {
    ...
  }(thought I'd share that since its raison d'être was to put Asciiquarium there :))
OLEDs can still suffer from burn-in, but it's also just easier to have them... turn off...
Do you know if this supports any DE (or no DE)? Or is it strictly for KDE Plasma?
When it comes to wallpapers, you could do a similar trick on X11 DEs by putting it onto the root window (with a tool like xwinwrap) and on Wayland DEs that support layer-shell (with a tool like windowtolayer). I'm not aware of screen lockers that do something like that, but you could always write your own one.
Yeah, I've used xwinwrap before, but am lost on Wayland. I'll look into windowtolayer, thanks. I'd rather not have to write this myself...
[1]: https://en.wikipedia.org/wiki/ANSI_escape_code#Control_Seque...
Screensavers are a lost art. I still enjoy them, but at some point we just gave up on them. In the era of CRTs they had a practical purpose (they're screen savers, after all), but modern OLED displays also suffer from burn-in for which screensavers would be useful. My enjoyment is purely aesthetic, though. Sometimes I just want to have something pleasing to glance at in the background, instead of a black screen.
Nowadays most operating systems and desktop environments don't even support them. The state of the art on Linux still seems to be `xscreensaver`, which does have many great ones, but the collection is static, and most of it is visually stuck in the 90s. I wouldn't even try getting it to run on Wayland, and when I last looked into it, it required some hacks and 3rd-party tools.
Also, I've always found the feature of screen locking and screen saving to be orthogonal. Often I want to see pretty graphics without locking my screen, and viceversa.
[0] https://github.com/attogram/bash-screensavers/blob/main/AGEN...
Also, found one of the easter eggs!
For folks curious about the rm -rf see https://github.com/attogram/bash-screensavers/blob/main/gall... line 339
    > /home/keeb/code/projects/login/motd.sh
    #!/usr/bin/env zsh
    values=("bubbles" "slide" "beams" "rain" "pour" "synthgrid" "unstable" "poop")
    len=${#values[@]}
    index=$(( (RANDOM % (len - 1)) + 1 ))
    selected=${values[$index]}
    cat /home/keeb/code/projects/login/motd | tte $selected
1: https://keeb.dev/static/login.mp4 2: https://github.com/ChrisBuilds/terminaltexteffects
First feature request: allow disabling all the `tput setab 0` calls throughout the codebase. This may make screensavers look weird on white terminals but should improve them for anyone using non-black-but-dark terminal themes.
    #!/usr/bin/env bash
    _cleanup_and_exit() {
      tput cnorm
      tput sgr0
      clear
      exit 0
    }
    trap _cleanup_and_exit SIGINT
    while true; do
      width=$(tput cols)
      height=$(tput lines)
      tput setab 0
      clear
      tput civis
      x=$((RANDOM % width + 1))
      y=$((RANDOM % height + 1))
      color_code=$((RANDOM % 256))
      printf "\e[${y};${x}H\e[38;5;${color_code}m"
      sleep 1
    doneAfter the printf, perhaps you want: tput smso; echo -n " "
Then I find moving the second "clear" before the "while" makes it more interesting. Not sure if that's more like what you intended.
A lot of screensavers, even historically, forget the original purpose of what "saving" your screen means.
What are those commit messages?
https://github.com/attogram/bash-screensavers/tree/a7369a93c...
(at least when running in docker, maybe that's the bottleneck, but I hesitated to run this on my machine directly)
I get "mapfile: command not found"
  cutesaver.sh: line 55: shuf: command not foundzmodload zsh/mapfile
new installs default to bash not being the default terminal. someone else mentioned macports, but there's a new version available via brew as well
./screensaver.sh: line 79: mapfile: command not found 1 .
(Press ^C to exit)
Choose your screensaver: 1 404 Screensaver Not Found:
Oh no! Screensaver had trouble! Error code: 1
checked active bash version:
echo $BASH_VERSION
5.3.3(1)-release
I found the 4k fullscreen perf in iTerm2 to be not-great, so I did it again in the kitty (GPU powered) terminal macos app, and it was good.
1: https://www.pcworld.com/article/2918628/your-oled-displays-w...
We used to have screensavers with CRT because it took them a lot of time to power on and most early CRTs didn't have power saving capabilities so showing something wasn't significantly worse than having a black screen in term of power usage.