diff options
Diffstat (limited to 'herbstluftwm')
| -rwxr-xr-x | herbstluftwm/.config/herbstluftwm/autostart | 7 | ||||
| -rw-r--r-- | herbstluftwm/.config/herbstluftwm/dependencylist | 12 | ||||
| -rwxr-xr-x | herbstluftwm/.config/herbstluftwm/panel.sh | 48 |
3 files changed, 45 insertions, 22 deletions
diff --git a/herbstluftwm/.config/herbstluftwm/autostart b/herbstluftwm/.config/herbstluftwm/autostart index edb6361..737fc11 100755 --- a/herbstluftwm/.config/herbstluftwm/autostart +++ b/herbstluftwm/.config/herbstluftwm/autostart | |||
| @@ -48,8 +48,8 @@ hc keybind $Mod-Shift-r reload | |||
| 48 | hc keybind $Mod-Shift-c close | 48 | hc keybind $Mod-Shift-c close |
| 49 | hc keybind $Mod-Return spawn xterm | 49 | hc keybind $Mod-Return spawn xterm |
| 50 | hc keybind $Mod-grave spawn dmenu_run $dmenu_opts | 50 | hc keybind $Mod-grave spawn dmenu_run $dmenu_opts |
| 51 | hc keybind XF86AudioLowerVolume spawn amixer -c 2 set Speaker 5%- | 51 | hc keybind XF86AudioLowerVolume spawn amixer set Master 1%- |
| 52 | hc keybind XF86AudioRaiseVolume spawn amixer -c 2 set Speaker 5%+ | 52 | hc keybind XF86AudioRaiseVolume spawn amixer set Master 1%+ |
| 53 | 53 | ||
| 54 | echo "env DISPLAY=:0 /usr/bin/dmenu_run $dmenu_opts" | 54 | echo "env DISPLAY=:0 /usr/bin/dmenu_run $dmenu_opts" |
| 55 | 55 | ||
| @@ -201,10 +201,11 @@ else | |||
| 201 | start_panel $panel | 201 | start_panel $panel |
| 202 | fi | 202 | fi |
| 203 | 203 | ||
| 204 | pulseaudio --start | ||
| 205 | |||
| 204 | $hlwm_scripts/start.sh "xautolock -time 5 -locker $hlwm_scripts/lock.sh" | 206 | $hlwm_scripts/start.sh "xautolock -time 5 -locker $hlwm_scripts/lock.sh" |
| 205 | $hlwm_scripts/start.sh "feh --bg-fill $wallpaper" | 207 | $hlwm_scripts/start.sh "feh --bg-fill $wallpaper" |
| 206 | $hlwm_scripts/start.sh "compton --config $HOME/.compton" | 208 | $hlwm_scripts/start.sh "compton --config $HOME/.compton" |
| 207 | $hlwm_scripts/start.sh "xrdb -load $HOME/.Xresources" | 209 | $hlwm_scripts/start.sh "xrdb -load $HOME/.Xresources" |
| 208 | $hlwm_scripts/start.sh "pulseaudio --start" | ||
| 209 | $hlwm_scripts/start.sh "dropboxd" | 210 | $hlwm_scripts/start.sh "dropboxd" |
| 210 | $hlwm_scripts/start.sh "$hlwm_scripts/notify.sh $monitor_w $window_p $panel_h $hlwm_scripts/popup.sh" | 211 | $hlwm_scripts/start.sh "$hlwm_scripts/notify.sh $monitor_w $window_p $panel_h $hlwm_scripts/popup.sh" |
diff --git a/herbstluftwm/.config/herbstluftwm/dependencylist b/herbstluftwm/.config/herbstluftwm/dependencylist index a18055d..d8275dd 100644 --- a/herbstluftwm/.config/herbstluftwm/dependencylist +++ b/herbstluftwm/.config/herbstluftwm/dependencylist | |||
| @@ -1,12 +1,14 @@ | |||
| 1 | compton | 1 | alsa-utils |
| 2 | bar-aint-recursive | 2 | bar-aint-recursive |
| 3 | bc | 3 | bc |
| 4 | wireless_tools | 4 | compton |
| 5 | dmenu2 | 5 | dmenu2 |
| 6 | feh | 6 | feh |
| 7 | pulseaudio | ||
| 8 | alsa-utils | ||
| 9 | sed | ||
| 10 | i3lock | 7 | i3lock |
| 8 | playerctl | ||
| 9 | pulseaudio | ||
| 10 | pulseaudio-alsa | ||
| 11 | scrot | 11 | scrot |
| 12 | sed | ||
| 13 | wireless_tools | ||
| 12 | xautolock | 14 | xautolock |
diff --git a/herbstluftwm/.config/herbstluftwm/panel.sh b/herbstluftwm/.config/herbstluftwm/panel.sh index 588e65e..8a2b0a4 100755 --- a/herbstluftwm/.config/herbstluftwm/panel.sh +++ b/herbstluftwm/.config/herbstluftwm/panel.sh | |||
| @@ -61,21 +61,33 @@ fi | |||
| 61 | # date ^fg(#efefef)18:33^fg(#909090), 2013-10-^fg(#efefef)29 | 61 | # date ^fg(#efefef)18:33^fg(#909090), 2013-10-^fg(#efefef)29 |
| 62 | 62 | ||
| 63 | while true ; do | 63 | while true ; do |
| 64 | # Music | ||
| 65 | player_status=$(playerctl status) | ||
| 66 | if [ $player_status = "Playing" ]; then | ||
| 67 | player_artist=$(playerctl metadata artist) | ||
| 68 | player_title=$(playerctl metadata title) | ||
| 69 | echo -e "music\tPlaying: $player_title - $player_artist" | ||
| 70 | else | ||
| 71 | echo -e "music\toff" | ||
| 72 | fi | ||
| 73 | |||
| 64 | # Volume | 74 | # Volume |
| 65 | volumes=$(\ | 75 | if pgrep pulseaudio >> /dev/null ; then |
| 66 | amixer get -c 2 get Speaker | \ | 76 | volumes=$(\ |
| 67 | grep "Front Right: Playback"\ | 77 | amixer get Master | \ |
| 68 | ) | 78 | grep "Front Right: Playback"\ |
| 69 | vol=$(\ | 79 | ) |
| 70 | echo $volumes | \ | 80 | vol=$(\ |
| 71 | sed "s/.*\[\([0-9]*\)%\].*/\1/"\ | 81 | echo $volumes | \ |
| 72 | ) | 82 | sed "s/.*\[\([0-9]*\)%\].*/\1/"\ |
| 73 | if [ -z $vol ] ; then | 83 | ) |
| 84 | if [ -z $vol ] ; then | ||
| 85 | echo -e "volume\toff" | ||
| 86 | else | ||
| 87 | echo -e "volume\t%{F$normal_txt}Vol: $vol%%%{F-}" | ||
| 88 | fi | ||
| 89 | else | ||
| 74 | echo -e "volume\toff" | 90 | echo -e "volume\toff" |
| 75 | elif [ $vol -le 0 ] ; then | ||
| 76 | echo -e "volume\t%{F$normal_txt}Volume muted" | ||
| 77 | else | ||
| 78 | echo -e "volume\t%{F$normal_txt}Volume: $vol%%%{F-}" | ||
| 79 | fi | 91 | fi |
| 80 | 92 | ||
| 81 | # Network | 93 | # Network |
| @@ -154,7 +166,7 @@ fi | |||
| 154 | echo -n "%{B-}%{F-} ${windowtitle//^/^^}" | 166 | echo -n "%{B-}%{F-} ${windowtitle//^/^^}" |
| 155 | 167 | ||
| 156 | #Right part of panel | 168 | #Right part of panel |
| 157 | right="$volume$net$battery$date " | 169 | right="$music$volume$net$battery$date " |
| 158 | echo -n "%{r}$right" | 170 | echo -n "%{r}$right" |
| 159 | echo | 171 | echo |
| 160 | 172 | ||
| @@ -165,6 +177,14 @@ fi | |||
| 165 | #echo "resetting tags" >&2 | 177 | #echo "resetting tags" >&2 |
| 166 | IFS=$'\t' read -ra tags <<< "$(hc tag_status $monitor)" | 178 | IFS=$'\t' read -ra tags <<< "$(hc tag_status $monitor)" |
| 167 | ;; | 179 | ;; |
| 180 | music) | ||
| 181 | music="${cmd[@]:1}" | ||
| 182 | if [ $music == "off" ] ; then | ||
| 183 | music="" | ||
| 184 | else | ||
| 185 | music="$music $separator%{B-} " | ||
| 186 | fi | ||
| 187 | ;; | ||
| 168 | volume) | 188 | volume) |
| 169 | volume="${cmd[@]:1}" | 189 | volume="${cmd[@]:1}" |
| 170 | if [ $volume == "off" ] ; then | 190 | if [ $volume == "off" ] ; then |
