worked on QML and other minor details

This commit is contained in:
Tomas Rivera
2026-03-14 18:53:29 +01:00
parent 1525781f35
commit e513f4c797
14 changed files with 351 additions and 16 deletions
+1
View File
@@ -202,6 +202,7 @@ in {
"custom-mountkdrive"
"waybar"
"custom-gitnotify"
"QS-notifycache" # builds the cache that will be used for the notification history
#########################
# login autostart
+17
View File
@@ -0,0 +1,17 @@
# creates and maintains cache file for the notification history
{
writeShellApplication,
...
}:
writeShellApplication {
name = "QS-notifycache";
runtimeInputs = [
];
text = ''
CACHE="$HOME/.cache/notify_history"
# Create or erase existing cache
mkdir -p "$(dirname "$CACHE")"
: > "$CACHE" # truncate file
echo "Notification history initialized at $(date)" >> "$CACHE"
'';
}
+31
View File
@@ -0,0 +1,31 @@
{
writeShellApplication,
...
}:
writeShellApplication {
name = "QS-notifyhistory";
runtimeInputs = [
];
text = ''
app="$1"
title="$2"
body="$3"
date="$(date +%T)"
urgency="$4"
case "$urgency" in
0) urgency_text="low";;
1) urgency_text="normal";;
2) urgency_text="critical";;
*) urgency_text="unknown";;
esac
{
echo "$app"
echo "$title"
echo "$body"
echo "$date"
echo "$urgency_text"
} >> "$HOME/.cache/notify_history"
'';
}
+1 -1
View File
@@ -47,7 +47,7 @@ for f in /sys/class/hwmon/hwmon*/fan*_input; do
count=$((count + 1))
fi
done
fan=$(( sum / count / 1000 ))
fan=$(( sum / count ))
fan=$(printf "%4s" "$fan")
mem=$(free | awk '/Mem:/ {printf("%.0f",$3/$2*100)}')