Skip to content

Commit a4d3e5d

Browse files
committed
v0.0.15 - Mystic Path
1 parent 6b16b61 commit a4d3e5d

File tree

3 files changed

+16
-17
lines changed

3 files changed

+16
-17
lines changed

README.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -41,19 +41,19 @@ cd bash-screensavers
4141
./screensaver.sh
4242
```
4343
```
44-
Bash Screensavers v0.0.14 (Mystic Canvas)
44+
Bash Screensavers v0.0.15 (Mystic Path)
4545
4646
1 . alpha - random colorful pixels
4747
2 . bouncing - bouncing 'O' madness
48-
3 . cutesaver - an infinite loop of cuteness
49-
4 . fireworks - elegant fireworks display
48+
3 . cutesaver - infinite loop of cuteness
49+
4 . fireworks - Ooh! Aah! Pretty lights!
5050
5 . matrix - the matrix has you
5151
6 . pipes - an endless pipe maze
5252
7 . rain - soothing, gentle rain
5353
8 . speaky - dramatic talking screensaver
54-
9 . stars - twinkling starfield simulation
54+
9 . stars - twinkling starfield
5555
10. tunnel - fly into the digital tunnel
56-
11. vibe - colorful plasma vibes
56+
11. vibe - vibe coding
5757
5858
(Press ^C to exit)
5959

gallery/speaky/speaky.sh

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -283,7 +283,7 @@ animate_text_rainbow() {
283283
# This gives the "streaming" effect
284284
local sleep_duration
285285
if [ "$len" -gt 0 ]; then
286-
sleep_duration=$(awk "BEGIN {print 5 / $len}")
286+
sleep_duration=$(awk "BEGIN {print 3 / $len}")
287287
else
288288
sleep_duration=0.1
289289
fi
@@ -304,9 +304,9 @@ animate_text_rainbow() {
304304
child_pid=$(pgrep -P $SPEAK_PID)
305305
if [ -n "$child_pid" ]; then
306306
# Wait for the actual player process, not the wrapper script
307-
timeout 10s wait "$child_pid" &>/dev/null
307+
timeout 25s wait "$child_pid" &>/dev/null
308308
else
309-
timeout 10s wait $SPEAK_PID &>/dev/null
309+
timeout 25s wait $SPEAK_PID &>/dev/null
310310
fi
311311
fi
312312
}

screensaver.sh

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -7,15 +7,14 @@
77
#
88

99
BASH_SCREENSAVERS_NAME='Bash Screensavers'
10-
BASH_SCREENSAVERS_VERSION='0.0.14'
11-
BASH_SCREENSAVERS_CODENAME='Mystic Canvas'
10+
BASH_SCREENSAVERS_VERSION='0.0.15'
11+
BASH_SCREENSAVERS_CODENAME='Mystic Path'
1212
BASH_SCREENSAVERS_URL='https://github.com/attogram/bash-screensavers'
1313
BASH_SCREENSAVERS_DISCORD='https://discord.gg/BGQJCbYVBa'
1414
BASH_SCREENSAVERS_LICENSE='MIT'
1515
BASH_SCREENSAVERS_COPYRIGHT='Copyright (c) 2025 Attogram Project <https://github.com/attogram>'
1616

17-
SCRIPT_DIR=$(cd -- "$(dirname -- "${BASH_SOURCE[0]}")" &> /dev/null && pwd)
18-
BASH_SCREENSAVERS_DIR="$SCRIPT_DIR/gallery"
17+
BASH_SCREENSAVERS_GALLERY="$(cd -- "$(dirname -- "${BASH_SOURCE[0]}")" &> /dev/null && pwd)/gallery"
1918

2019
chosen_screensaver='' # the chosen one
2120

@@ -24,7 +23,7 @@ chosen_screensaver='' # the chosen one
2423
# Output: list of screensaver run scripts, 1 per line
2524
peak_into_the_gallery() {
2625
local screensaver name run
27-
for screensaver in "$BASH_SCREENSAVERS_DIR"/*/; do
26+
for screensaver in "$BASH_SCREENSAVERS_GALLERY"/*/; do
2827
if [[ -d "${screensaver}" ]]; then
2928
name="$(basename "${screensaver}")"
3029
run="${screensaver}${name}.sh"
@@ -70,7 +69,7 @@ choose_screensaver() {
7069
local screensavers
7170
mapfile -t screensavers < <(peak_into_the_gallery)
7271
if [[ ${#screensavers[@]} -eq 0 ]]; then
73-
echo "Whoops! No screensavers found. Add some to the '$BASH_SCREENSAVERS_DIR' directory."
72+
echo "Whoops! No screensavers found. Add some to the '$BASH_SCREENSAVERS_GALLERY' directory."
7473
echo
7574
exit 1
7675
fi
@@ -106,8 +105,8 @@ choose_screensaver() {
106105

107106
local choice
108107
echo
109-
echo 'Choose your screensaver:'
110-
read -e choice
108+
echo -n 'Choose your screensaver: '
109+
read -r -e choice
111110

112111
if [[ "$choice" =~ ^[0-9]+$ ]]; then # Check if choice is a number
113112
if [ "$choice" -ge 1 ] && [ "$choice" -le "${#screensavers[@]}" ]; then
@@ -133,7 +132,7 @@ choose_screensaver() {
133132

134133
create_new_screensaver() {
135134
local name="$1"
136-
local dir="$BASH_SCREENSAVERS_DIR/$name"
135+
local dir="$BASH_SCREENSAVERS_GALLERY/$name"
137136

138137
if [ -d "$dir" ]; then
139138
echo "Error: screensaver '$name' already exists at $dir" >&2

0 commit comments

Comments
 (0)