aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authordx <aryadevchavali1@gmail.com>2020-07-09 22:07:30 +0100
committerdx <aryadevchavali1@gmail.com>2020-07-09 22:10:05 +0100
commit7e3e104baccc34b5583f7695f1a4d3768541fc94 (patch)
treeea9a708ac3379a1e7404dfa48d61d5e880624ac9
parent31516c31c18bbcd37699e47bee1ddb499bfb2943 (diff)
downloaddotfiles-7e3e104baccc34b5583f7695f1a4d3768541fc94.tar.gz
dotfiles-7e3e104baccc34b5583f7695f1a4d3768541fc94.tar.bz2
dotfiles-7e3e104baccc34b5583f7695f1a4d3768541fc94.zip
+script to update dwmbar based on music changes
-rw-r--r--SXHkD/.config/sxhkd/sxhkdrc2
-rwxr-xr-xScripts/.local/scripts/status/music_update_bar12
-rw-r--r--XServer/.xinitrc4
3 files changed, 16 insertions, 2 deletions
diff --git a/SXHkD/.config/sxhkd/sxhkdrc b/SXHkD/.config/sxhkd/sxhkdrc
index b80a1ea..36dc3b8 100644
--- a/SXHkD/.config/sxhkd/sxhkdrc
+++ b/SXHkD/.config/sxhkd/sxhkdrc
@@ -45,12 +45,10 @@ super + F12
# Music and volume
F{6,7,8}
mpc -q {prev,toggle,next}; \
- kill -45 $(pidof dwmblocks); \
notify-send "MPD: Track $(mpc --format '%title%' | head -1)";
XF86Audio{Prev,Next}
mpc -q {prev,next}; \
- kill -45 $(pidof dwmblocks); \
notify-send "MPD: Track $(mpc --format '%title%' | head -1)";
{_,hyper + }F{9,10}
diff --git a/Scripts/.local/scripts/status/music_update_bar b/Scripts/.local/scripts/status/music_update_bar
new file mode 100755
index 0000000..7691f36
--- /dev/null
+++ b/Scripts/.local/scripts/status/music_update_bar
@@ -0,0 +1,12 @@
+#!/bin/bash
+
+while :
+do
+ while [[ $item != "player" && $item != "playlist" ]]
+ do
+ sleep 0.01;
+ item=$(mpc idle | head -1);
+ done
+ kill -45 $(pidof dwmblocks);
+ item="";
+done
diff --git a/XServer/.xinitrc b/XServer/.xinitrc
index ca6330e..e41c949 100644
--- a/XServer/.xinitrc
+++ b/XServer/.xinitrc
@@ -6,14 +6,18 @@ killall sxhkd;
sh .xprofile;
xset s 1800;
+
$(xss-lock --transfer-sleep-lock -- lock) &
feh --randomize --bg-scale $HOME/Pictures/Backgrounds &
+
$HOME/.local/scripts/eserver start &
+$HOME/.local/scripts/status/music_update_bar &
dunst &
picom &
mpd &
sxhkd &
dwmblocks &
+
# $HOME/.config/bspwm/bspwmrc
while :; do
ssh-agent dwm