dotfiles

config files and scripts
git clone git://git.hanetzok.net/dotfiles
Log | Files | Refs

commit f35311f9ad5476608e2dde8a874dae69860771d5
parent 5447b75893254eee14831a904020ed8c162a1781
Author: Markus Hanetzok <markus@hanetzok.net>
Date:   Sun,  6 Jul 2025 22:20:42 +0200

add some scripts

Diffstat:
A.local/bin/setbg | 14++++++++++++++
A.local/bin/status | 12++++++++++++
A.local/bin/sysmenu | 9+++++++++
3 files changed, 35 insertions(+), 0 deletions(-)

diff --git a/.local/bin/setbg b/.local/bin/setbg @@ -0,0 +1,14 @@ +#!/bin/sh + +bg="$XDG_DATA_HOME"/wallpaper + +if [ ! -z "$1" ]; then + file="$(realpath $1)" + cp "$file" "$bg" +fi + +if [ -f "$bg" ]; then + xwallpaper --center "$bg" +fi + + diff --git a/.local/bin/status b/.local/bin/status @@ -0,0 +1,12 @@ +#!/bin/sh + + + +while true; do + dt="$(date +"%y/%m/%d | %H:%M")" + [[ -d /sys/class/power_supply/BAT0 ]] && bat="| $(cat /sys/class/power_supply/BAT0/capacity)" + vol="$(pamixer --get-volume-human)" + + xsetroot -name "$dt | VOL: $vol $bat " + sleep 1 +done diff --git a/.local/bin/sysmenu b/.local/bin/sysmenu @@ -0,0 +1,9 @@ +#!/bin/sh + +case "$(printf "lock\nshutdown\nreboot\nsleep" | dmenu -i -p 'Action: ')" in + "lock") slock ;; + "shutdown") systemctl poweroff ;; + "reboot") systemctl reboot -i ;; + "sleep") slock systemctl suspend -i ;; + *) exit 1 ;; +esac