Add util scripts + volume key bindings
This commit is contained in:
parent
f0ecb3a500
commit
e39f888050
@ -389,6 +389,16 @@
|
|||||||
<command>dmenu_run</command>
|
<command>dmenu_run</command>
|
||||||
</action>
|
</action>
|
||||||
</keybind>
|
</keybind>
|
||||||
|
<keybind key="XF86AudioRaiseVolume">
|
||||||
|
<action name="Execute">
|
||||||
|
<command>volume_up.sh</command>
|
||||||
|
</action>
|
||||||
|
</keybind>
|
||||||
|
<keybind key="XF86AudioLowerVolume">
|
||||||
|
<action name="Execute">
|
||||||
|
<command>volume_down.sh</command>
|
||||||
|
</action>
|
||||||
|
</keybind>
|
||||||
</keyboard>
|
</keyboard>
|
||||||
<mouse>
|
<mouse>
|
||||||
<dragThreshold>1</dragThreshold>
|
<dragThreshold>1</dragThreshold>
|
||||||
|
3
my_home/bin/show_battery.sh
Executable file
3
my_home/bin/show_battery.sh
Executable file
@ -0,0 +1,3 @@
|
|||||||
|
#!/usr/bin/env sh
|
||||||
|
|
||||||
|
envstat -s "acpibat0:charge,acpibat1:charge"
|
3
my_home/bin/sleep_laptop.sh
Executable file
3
my_home/bin/sleep_laptop.sh
Executable file
@ -0,0 +1,3 @@
|
|||||||
|
#!/usr/bin/env sh
|
||||||
|
|
||||||
|
sysctl -w hw.acpi.sleep.state=3
|
5
my_home/bin/volume_down.sh
Executable file
5
my_home/bin/volume_down.sh
Executable file
@ -0,0 +1,5 @@
|
|||||||
|
#!/usr/bin/env sh
|
||||||
|
|
||||||
|
volume_level=`mixerctl -n outputs.master | cut -d ',' -f 1`
|
||||||
|
|
||||||
|
mixerctl -w outputs.master=`expr $volume_level - 10`
|
5
my_home/bin/volume_up.sh
Executable file
5
my_home/bin/volume_up.sh
Executable file
@ -0,0 +1,5 @@
|
|||||||
|
#!/usr/bin/env sh
|
||||||
|
|
||||||
|
volume_level=`mixerctl -n outputs.master | cut -d ',' -f 1`
|
||||||
|
|
||||||
|
mixerctl -w outputs.master=`expr $volume_level + 10`
|
3
my_home/bin/watch_battery.sh
Executable file
3
my_home/bin/watch_battery.sh
Executable file
@ -0,0 +1,3 @@
|
|||||||
|
#!/usr/bin/env sh
|
||||||
|
|
||||||
|
envstat -s "acpibat0:charge,acpibat1:charge" -i 60
|
Loading…
x
Reference in New Issue
Block a user