summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xbin/.local/bin/statusbar32
-rw-r--r--x/.xinitrc7
2 files changed, 28 insertions, 11 deletions
diff --git a/bin/.local/bin/statusbar b/bin/.local/bin/statusbar
index 00b5d2b..c506244 100755
--- a/bin/.local/bin/statusbar
+++ b/bin/.local/bin/statusbar
@@ -1,29 +1,45 @@
1#!/bin/bash 1#!/bin/bash
2 2
3BOLD='\033[1m' 3# Color definitions.
4BB='\033[00m' 4export BLK="\e[30m"
5export RED="\e[31m"
6export GRN="\e[32m"
7export YLW="\e[33m"
8export BLU="\e[34m"
9export PUR="\e[35m"
10export CYN="\e[36m"
11export RST="\e[0m"
12
13# Other formatting.
14export BLD="\e[1m"
15export DIM="\e[2m"
16export ITA="\e[3m"
17export UND="\e[4m"
18export FLS="\e[5m"
19export REV="\e[7m"
20export INV="\e[8m"
21export STR="\e[9m"
5 22
6vol(){ 23vol(){
7 vol=$(pulsemixer --get-volume | awk '{print $1}') 24 vol=$(pulsemixer --get-volume | awk '{print $1}')
8 echo -e "vol $vol% " 25 echo -e "vol $vol%"
9} 26}
10 27
11bat() { 28bat() {
12 power=$(cat /sys/class/power_supply/BAT0/capacity) 29 power=$(cat /sys/class/power_supply/BAT0/capacity)
13 echo -e "bat $power% " 30 echo -e "bat $power%"
14} 31}
15 32
16dte() { 33dte() {
17 dte=$(date +"%A, %B %d") 34 dte=$(date +"%A, %B %d")
18 echo -e "date $dte " 35 echo -e "date $dte"
19} 36}
20 37
21tie() { 38tie() {
22 tme=$(date +"%I:%M %p") 39 tme=$(date +"%I:%M %p")
23 echo -e "time $tme " 40 echo -e "time $tme"
24} 41}
25
26while :; do 42while :; do
27 echo "$(vol) $(bat) $(tie) $(dte)" 43 echo "$(vol) $(bat) $(tie) $(dte)"
28 sleep 2 44 sleep 2
29done 45done
diff --git a/x/.xinitrc b/x/.xinitrc
index 4a4f7d0..5ad4ab7 100644
--- a/x/.xinitrc
+++ b/x/.xinitrc
@@ -1,9 +1,10 @@
1#exec dbus-launch --exit-with-session spectrwm 1#!/bin/bash
2#xrdb ~/.Xresources & 2#.xinitrc
3xset b off & 3xset b off &
4xset s 600 & 4xset s 600 &
5~/bin/xss & 5~/bin/xss &
6~/.fehbg & 6~/.fehbg &
7picom 2>/dev/null & 7picom 2>/dev/null &
8xsetroot -name "bat $(cat /sys/class/power_supply/BAT0/capacity)" 8dwmbar &
9
9exec dbus-launch --exit-with-session startdwm 10exec dbus-launch --exit-with-session startdwm