summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorxyz <gky44px1999@gmail.com>2021-08-28 19:11:06 -0700
committerxyz <gky44px1999@gmail.com>2021-08-28 19:11:06 -0700
commit2f950ab04fbac5879b0e29c87bf47d07672e31f5 (patch)
treec291d6ce95b9947275da743a998cae0ad8b6b34e
parentf31301016e3a3b92fdf1536897c1e23f0b886155 (diff)
switch to pulseaudio
-rw-r--r--.bashrc1
-rw-r--r--.config/sxhkd/sxhkdrc6
-rwxr-xr-x.local/bin/set_dwm_status_bar4
3 files changed, 10 insertions, 1 deletions
diff --git a/.bashrc b/.bashrc
index 7601d40a..d333aedb 100644
--- a/.bashrc
+++ b/.bashrc
@@ -25,6 +25,7 @@ PS1="\[\e[0;91m\][\u@\h \W]\$ \[\e[0m\]"
alias \
absolutely-proprietary="absolutely-proprietary -f" \
+alsamixer="alsamixer -V all" \
diff="diff --color=auto" \
grep="grep --color=auto" \
ls="ls --color=auto" \
diff --git a/.config/sxhkd/sxhkdrc b/.config/sxhkd/sxhkdrc
index 528ddcdc..3ac31ee6 100644
--- a/.config/sxhkd/sxhkdrc
+++ b/.config/sxhkd/sxhkdrc
@@ -6,6 +6,12 @@ alt + Print
XF86Audio{RaiseVolume,LowerVolume,Mute}
amixer set Master {5%+,5%-,toggle}
+# for pulseaudio, master volume affects capture volume too?
+# my laptop built-in microphone capture volume is really low
+# so I want to keep capture volume always 100%
+shift + XF86AudioMute
+ amixer set Capture toggle
+
alt + y
mpvsel || notify-send "mpvsel failed"
diff --git a/.local/bin/set_dwm_status_bar b/.local/bin/set_dwm_status_bar
index bfae853b..7f506f23 100755
--- a/.local/bin/set_dwm_status_bar
+++ b/.local/bin/set_dwm_status_bar
@@ -4,8 +4,10 @@ xsetroot -name "$(date '+%a %m/%d %H:%M') \
| $(TZ=Asia/Shanghai date '+/%d %H:') \
| $(if xset q | grep -q "Caps Lock: *on"; then echo A; else echo a; fi) \
| $(cat /sys/class/net/wlp6s0/operstate) \
-| $(amixer get Master | awk -F'[][]' 'END{ print $6" "$2 }') \
+| $(amixer get Master | awk -F'[][]' 'END{print "M "$4" "$2}') \
+| $(amixer get Capture | awk -F'[][]' 'END{print "C "$4}') \
| $(cat /sys/class/power_supply/BAT1/capacity)%"
+#| $(amixer get Master | awk -F'[][]' 'END{ print $6" "$2 }') \
#| $(free -h | awk '(NR==2){ print $4 }') \
#| $(sed 's/000$/°C/' /sys/class/thermal/thermal_zone0/temp) \