From 5bc01819f4c9b453e5b66994217aa61260a49201 Mon Sep 17 00:00:00 2001 From: Shubham Saini Date: Sun, 17 May 2020 17:10:22 +0530 Subject: changes --- spectrwm/.config/spectrwm/statusbar | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100755 spectrwm/.config/spectrwm/statusbar (limited to 'spectrwm/.config') diff --git a/spectrwm/.config/spectrwm/statusbar b/spectrwm/.config/spectrwm/statusbar new file mode 100755 index 0000000..c90c1df --- /dev/null +++ b/spectrwm/.config/spectrwm/statusbar @@ -0,0 +1,30 @@ +#!/bin/bash + +BOLD='\033[1m' +BB='\033[00m' + +vol(){ + vol=$(pulsemixer --get-volume | awk '{print $1}') + echo -e "+@fg=1;vol+@fg=0; $vol% " +} + +bat() { + power=$(cat /sys/class/power_supply/BAT0/capacity) + echo -e "+@fg=1;bat+@fg=0; $power% " +} + +dte() { + dte=$(date +"%A, %B %d") + echo -e "+@fg=1;date+@fg=0; $dte " +} + +tie() { + tme=$(date +"%I:%M %p") + echo -e "+@fg=1;time+@fg=0; $tme " +} + +while :; do + echo "$(vol) $(bat) $(tie) $(dte)" + sleep 2 +done + -- cgit v1.2.3