1
0
mirror of https://github.com/tiyn/dotfiles.git synced 2025-04-17 07:17:47 +02:00

Compare commits

...

3 Commits

Author SHA1 Message Date
7e576a888e updated readme setup 2024-04-06 00:53:19 +02:00
9822eba605 updated keymaps 2024-04-06 00:50:26 +02:00
53c8e1159f sxhkd/statusbar: added scripts for dunst dnd mode 2024-04-06 00:34:38 +02:00
8 changed files with 87 additions and 44 deletions

View File

@ -32,6 +32,8 @@ super + bracketright
lmc mute_toggle lmc mute_toggle
super + backslash super + backslash
lmc deaf_toggle lmc deaf_toggle
super + bracketleft
dnd toggle
super + shift + l super + shift + l
keymap_toggle keymap_toggle

View File

@ -20,5 +20,11 @@ else
mic="^c#dfdfdf^  " mic="^c#dfdfdf^  "
fi fi
if [ -f ~/.local/state/dnd_mode.lock ]; then
notifications="^c#ff0000^  "
else
notifications="^c#dfdfdf^  "
fi
vol=$(printf %3s $vol | tr ' ' ' ') vol=$(printf %3s $vol | tr ' ' ' ')
printf "^b#282828^%s%s^d^" "$mic" "$vol_info" printf "^b#282828^%s%s%s^d^" "$mic" "$vol_info" "$notifications"

42
.local/bin/etc/sxhkd/dnd/dnd Executable file
View File

@ -0,0 +1,42 @@
#!/bin/sh
# Script to easily manage a do not disturb mode for dunst
case "$1" in
start)
# notify-send -u low "dunst" "Do not disturb started"
dunstctl history-clear
dunstctl rule dnd_low enable
dunstctl rule dnd_normal enable
dunstctl rule sound_normal disable
touch ~/.local/state/dnd_mode.lock
pkill -RTMIN+4 $STATUSBAR
paplay ~/.local/bin/etc/sxhkd/dnd/notifications_disabled.mp3 ;;
stop)
# notify-send -u low "dunst" "Do not disturb stopped"
dunstctl rule dnd_low disable
dunstctl rule dnd_normal disable
dunstctl rule sound_normal enable
hist_size=$(dunstctl history | jq '.data[0] | length')
for i in `seq $hist_size`; do
dunstctl history-pop
done
rm ~/.local/state/dnd_mode.lock
pkill -RTMIN+4 $STATUSBAR
paplay ~/.local/bin/etc/sxhkd/dnd/notifications_enabled.mp3 ;;
toggle)
if [ -f ~/.local/state/dnd_mode.lock ]; then
dnd stop
else
dnd start
fi ;;
*) cat << EOF
dnd: dunst interface to manage a do-not-disturb-mode.
Allowed options:
start Enable do-not-disturb-mode
stop Disable do-not-disturb-mode
toggle Toggle sound
EOF
esac

Binary file not shown.

Binary file not shown.

View File

@ -1,7 +0,0 @@
#!/bin/sh
notify-send -u low "dunst" "Do not disturb started"
dunstctl history-clear
dunstctl rule dnd_low enable
dunstctl rule dnd_normal enable
dunstctl rule sound_normal disable

View File

@ -1,10 +0,0 @@
#!/bin/sh
dunstctl rule dnd_low disable
dunstctl rule dnd_normal disable
dunstctl rule sound_normal enable
hist_size=$(dunstctl history | jq '.data[0] | length')
for i in `seq $hist_size`; do
dunstctl history-pop
done
notify-send -u low "dunst" "Do not disturb stopped"

View File

@ -27,7 +27,7 @@ xargs -I{} mv {} .config-backup/{}
- ignore untracked files: `config config --local status.showUntrackedFiles no` - ignore untracked files: `config config --local status.showUntrackedFiles no`
- pull current setup: `config pull` - pull current setup: `config pull`
- finish setup for vim: - finish setup for vim:
- open vim and run `:PackerCompile`, and `:PackerInstall` - open vim
The step containing commenting out is needed because the colorscheme has The step containing commenting out is needed because the colorscheme has
problems being not available and disrupts the further process of the plugin problems being not available and disrupts the further process of the plugin
@ -48,31 +48,41 @@ There are various shortcuts and hotkeys used in this version. Included in my bui
| ModKey | Shift | Key | Function | | ModKey | Shift | Key | Function |
| ------ | ----- | ----------------- | --------------------------------------------------------- | | ------ | ----- | ----------------- | --------------------------------------------------------- |
| Super | | b | Spawn browser | | Super | | a | (sounds) Previous song |
| Super | | f | Spawn filemanager | | Super | | b | (program) Spawn browser |
| Super | | i | (gpu-screen-record) stop recording | | Super | | c | (sounds) Toggle looping of songs |
| Super | | m | Spawn thunderbird | | Super | | d | (sounds) Next song |
| Super | | o | (gpu-screen-record) start replay | | Super | | f | (program) Spawn filemanager |
| Super | | p | (gpu-screen-record) save replay | | Super | | i | (display) Stop recording |
| Super | | u | (gpu-screen-record) start recording | | Super | | m | (program) Spawn thunderbird |
| Super | | r | (dmenu) dmenu\_run | | Super | | o | (display) Start replay window |
| Super | Shift | x | Restart sxkd | | Super | | p | (display) Save replay window |
| Super | | F5 | Enable 2 Screen Monitor | | Super | | u | (display) Start recording window |
| Super | | F6 | Toggle touchpad | | Super | | r | (program) Spawn dmenu\_run |
| Super | | F7 | (dmenu) Mounting drives | | Super | | s | (sounds) Pause song |
| Super | | F8 | (dmenu) Unmounting drives | | Super | | x | (sounds) Toggle shuffling of songs |
| Super | | F9 | Restart NetworkManager | | Super | Shift | l | (keyboard) Toggle keymap |
| Super | | F10 | (dmenu) Prompt, if yes: slock | | Super | Shift | r | (sxhkd) Restart sxkd |
| Super | | F11 | (dmenu) Prompt, if yes: reboot | | Super | Shift | Space | (notifications) Close all notifications |
| Super | | F12 | (dmenu) Prompt, if yes: shutdown | | Super | | [ | (notifications) Toggle dunst dnd |
| Super | | Print | (dmenu) Prompt to take a screenshot | | Super | | ] | (sounds) Toggle mute |
| Super | | Return | Spawn terminal | | Super | | \ | (sounds) Toggle deaf |
| | | AudioMute | Volume mute | | Super | | F5 | (display) Enable 2 Screen Monitor |
| | | AudioMicMute | Mic Mute | | Super | | F6 | (keyboard) Toggle touchpad |
| | | AudioLowerVolume | Volume lower | | Super | | F7 | (mounting) Mounting drives |
| | | AudioRaiseVolume | Volume raise | | Super | | F8 | (mounting) Unmounting drives |
| | | MonBrightnessDown | Brightness decrease | | Super | | F9 | (network) Restart NetworkManager |
| | | MonBrightnessUp | Brightness increase | | Super | | F10 | (display) slock |
| Super | | F11 | (shutdown) reboot |
| Super | | F12 | (shutdown) shutdown |
| Super | | Return | (program) Spawn terminal |
| | | Print | (program) Prompt to take a screenshot |
| | | AudioMute | (sound) Volume mute |
| | | AudioMicMute | (sound) Mic Mute |
| | | AudioLowerVolume | (sound) Volume lower |
| | | AudioRaiseVolume | (sound) Volume raise |
| | | MonBrightnessDown | (display) Brightness decrease |
| | | MonBrightnessUp | (display) Brightness increase |
## Additional configs ## Additional configs