aboutsummaryrefslogtreecommitdiffstats
path: root/bin
diff options
context:
space:
mode:
Diffstat (limited to '')
-rwxr-xr-xbin/.local/bin/get-password (renamed from executables/bin/get-password)0
-rwxr-xr-xbin/.local/bin/gh-clone-all (renamed from executables/bin/gh-clone-all)0
-rwxr-xr-xbin/.local/bin/migrate-to-sourcehut (renamed from executables/bin/migrate-to-sourcehut)0
-rwxr-xr-xbin/.local/bin/optimize-image (renamed from executables/bin/optimize-image)0
-rwxr-xr-xbin/.local/bin/sct-daemon18
5 files changed, 18 insertions, 0 deletions
diff --git a/executables/bin/get-password b/bin/.local/bin/get-password
index 3b83bb7..3b83bb7 100755
--- a/executables/bin/get-password
+++ b/bin/.local/bin/get-password
diff --git a/executables/bin/gh-clone-all b/bin/.local/bin/gh-clone-all
index 77de93a..77de93a 100755
--- a/executables/bin/gh-clone-all
+++ b/bin/.local/bin/gh-clone-all
diff --git a/executables/bin/migrate-to-sourcehut b/bin/.local/bin/migrate-to-sourcehut
index d7e471a..d7e471a 100755
--- a/executables/bin/migrate-to-sourcehut
+++ b/bin/.local/bin/migrate-to-sourcehut
diff --git a/executables/bin/optimize-image b/bin/.local/bin/optimize-image
index 075684b..075684b 100755
--- a/executables/bin/optimize-image
+++ b/bin/.local/bin/optimize-image
diff --git a/bin/.local/bin/sct-daemon b/bin/.local/bin/sct-daemon
new file mode 100755
index 0000000..b16a67e
--- /dev/null
+++ b/bin/.local/bin/sct-daemon
@@ -0,0 +1,18 @@
+#!/bin/sh
+set -e
+
+while true; do
+ hour=$(date +%H)
+
+ if [ "$hour" -ge 6 ] && [ "$hour" -lt 18 ]; then
+ sct 6500 # day
+ elif [ "$hour" -ge 18 ] && [ "$hour" -lt 20 ]; then
+ sct 4500 # evening
+ elif [ "$hour" -ge 20 ] && [ "$hour" -lt 22 ]; then
+ sct 3500 # night
+ else
+ sct 3000 # late night/early morning
+ fi
+
+ sleep 600 # check every 10 minutes
+done