summaryrefslogtreecommitdiff
path: root/countdown
diff options
context:
space:
mode:
authorDavid Wührer <def@gmx.at>2024-05-18 21:04:34 +0200
committerDavid Wührer <def@gmx.at>2024-05-18 21:04:34 +0200
commit77cfffee6177fb0421fa0fce15d6a1875bde4816 (patch)
tree251428cdd482ea50cfb019dbd3c3bafd79d2fd14 /countdown
parent75b23ce1ff0daab363725a2a5755ea80bbeaa68e (diff)
manuals, sum-down, radix
Diffstat (limited to 'countdown')
-rwxr-xr-xcountdown23
1 files changed, 0 insertions, 23 deletions
diff --git a/countdown b/countdown
deleted file mode 100755
index 59daf56..0000000
--- a/countdown
+++ /dev/null
@@ -1,23 +0,0 @@
-#!/bin/bash
-
-declare -i t=$1
-
-while [ $((t--)) -ne 0 ]; do
- if [ $t -gt 5400 ]; then
- h=$((t/3600))
- m=$(((t-(h*3600))/60))
- if [ $m -lt 10 ]; then m=0$m; fi
- s=$((t%60))
- if [ $s -lt 10 ]; then s=0$s; fi
- echo -en "\r$h:$m:$s "
- elif [ $t -gt 90 ]; then
- m=$((t/60))
- s=$((t%60))
- if [ $s -lt 10 ]; then s=0$s; fi
- echo -en "\r$m:$s "
- else
- echo -en "\r$t "
- fi
- sleep 1
-done
-echo -en "\r"