diff options
-rwxr-xr-x | n | 2 | ||||
-rwxr-xr-x | sysinfo | 24 | ||||
-rwxr-xr-x | wal | 3 | ||||
-rwxr-xr-x | weather | 2 |
4 files changed, 31 insertions, 0 deletions
@@ -0,0 +1,2 @@ +#!/usr/bin/env bash +notify-send $1 "$("$@")" @@ -0,0 +1,24 @@ +#!/usr/bin/env bash +#A simple popup showing system information + +HOST=$(uname -n) +KERNEL=$(uname -r) +UPTIME=$( uptime | sed 's/.* up //' | sed 's/[0-9]* us.*//' | sed 's/ day, /d /'\ + | sed 's/ days, /d /' | sed 's/:/h /' | sed 's/ min//'\ + | sed 's/,/m/' | sed 's/ / /') +PACKAGES=$(nix-env -q | wc -l) +#UPDATED=$(awk '/upgraded/ {line=$0;} END { $0=line; gsub(/[\[\]]/,"",$0); \ +# printf "%s %s",$1,$2;}' /var/log/pacman.log) + +( +echo "System Information" # Fist line goes to title +# The following lines go to slave window +echo "host: $HOST " +echo "kernel: $KERNEL" +echo "uptime: $UPTIME " +echo "$PACKAGES packages" +#echo "Last updated on: $UPDATED" +) | dzen2 -p -x "500" -y "30" -w "220" -l "5" -sa 'l' -ta 'c'\ + -title-name 'popup_sysinfo' -e 'onstart=uncollapse;button1=exit;button3=exit' + +# "onstart=uncollapse" ensures that slave window is visible from start.
\ No newline at end of file @@ -0,0 +1,3 @@ +#!/usr/bin/env bash +file=$(ls ~/wallpaper | sort -R | tail -1) +feh --bg-fill ~/wallpaper/$file
\ No newline at end of file @@ -0,0 +1,2 @@ +#!/usr/bin/env bash +curl wttr.in/92101 |