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

Compare commits

..

No commits in common. "af9989106fc5190d1d8477775617880549ee582c" and "3917ffaa7c8e07922b121acb131440849681c6b2" have entirely different histories.

20 changed files with 53 additions and 70 deletions

View File

@ -29,12 +29,12 @@ super + m
thunderbird
super + bracketright
lmc mute_toggle
mic_toggle
super + backslash
lmc deaf_toggle
sound_toggle
super + shift + l
keymap_toggle
change_keymap
super + shift + r
pkill -usr1 -x sxhkd ; notify-send -u low 'SXHKD' 'Reloaded config'
@ -43,7 +43,7 @@ super + Return
$TERMINAL
Print
screenshot_menu
screenshotmenu
super + shift + space
dunstctl close-all
@ -53,9 +53,9 @@ super + F5
super + F6
touchpad_toggle
super + F7
mount_menu
dmenumount
super + F8
umount_menu
dmenuumount
super + F9
sudo -A systemctl restart NetworkManager ; notify-send -u low 'Network' 'Restartet NM'
super + F10
@ -66,9 +66,9 @@ super + F12
prompt "Reboot computer?" "sudo -A reboot now"
XF86AudioMute
lmc deaf_toggle
sound_toggle
XF86AudioMicMute
lmc mute_toggle
mic_toggle
XF86AudioLowerVolume
lmc down
XF86AudioRaiseVolume

View File

@ -2,7 +2,7 @@
while read file
do
case "$1" in
"w") background_set "$file" & ;;
"w") setbg "$file" & ;;
"c")
[ -z "$destdir" ] && destdir="$(sed "s/\s.*#.*$//;/^\s*$/d" ~/.config/bmdirs | awk '{print $2}' | dmenu -l 20 -i -p "Copy file(s) to where?" | sed "s|~|$HOME|g")"
[ -z "$destdir" ] && exit

View File

@ -2,75 +2,38 @@
# A general audio interface for LARBS.
# Based on a script by lukesmithxyz, checkout github.com/lukesmithxyz/voidrice
# Heavily extended and updated to a pipewire system
[ -z "$2" ] && num="5" || num="$2"
case "$1" in
up) wpctl set-volume @DEFAULT_AUDIO_SINK@ "$num"%+
pkill -RTMIN+4 $STATUSBAR ;;
down) wpctl set-volume @DEFAULT_AUDIO_SINK@ "$num"%-
pkill -RTMIN+4 $STATUSBAR ;;
deaf) wpctl set-mute @DEFAULT_SINK@ 1
pkill -RTMIN+4 $STATUSBAR ;;
undeaf) wpctl set-mute @DEFAULT_SINK@ 0
pkill -RTMIN+4 $STATUSBAR ;;
mute) wpctl set-mute @DEFAULT_AUDIO_SOURCE@ 1
pkill -RTMIN+4 $STATUSBAR ;;
unmute) wpctl set-mute @DEFAULT_AUDIO_SOURCE@ 0
pkill -RTMIN+4 $STATUSBAR ;;
deaf_toggle)
if amixer get Master | tail -2 | grep -q '\[on\]'; then
notify-send -u low 'sxhkd' 'Sound muted\nMicrophone muted'
lmc mute
lmc deaf
else
lmc mute
lmc undeaf
paplay ~/.local/bin/etc/sxhkd/audio/sound_resumed.wav
fi ;;
mute_toggle)
if amixer get Capture | tail -2 | grep -q '\[on\]'; then
lmc mute
lmc undeaf
paplay ~/.local/bin/etc/sxhkd/audio/mic_muted.wav
else
lmc unmute
lmc undeaf
paplay ~/.local/bin/etc/sxhkd/audio/mic_activated.wav
fi ;;
previous) playerctl previous
sleep 1
pkill -RTMIN+9 $STATUSBAR ;;
playpause) playerctl play-pause
sleep 1
pkill -RTMIN+9 $STATUSBAR ;;
next) playerctl next
sleep 1
pkill -RTMIN+9 $STATUSBAR ;;
shuffle) playerctl shuffle toggle
sleep 1
pkill -RTMIN+9 $STATUSBAR ;;
loop) playerctl loop none
sleep 1
pkill -RTMIN+9 $STATUSBAR ;;
*) cat << EOF
up) wpctl set-volume @DEFAULT_AUDIO_SINK@ "$num"%+ ;;
down) wpctl set-volume @DEFAULT_AUDIO_SINK@ "$num"%- ;;
deaf) wpctl set-mute @DEFAULT_SINK@ 1;;
undeaf) wpctl set-mute @DEFAULT_SINK@ 0;;
mute) wpctl set-mute @DEFAULT_AUDIO_SOURCE@ 1;;
unmute) wpctl set-mute @DEFAULT_AUDIO_SOURCE@ 0;;
previous) playerctl previous;;
playpause) playerctl play-pause;;
next) playerctl next;;
shuffle) playerctl shuffle toggle;;
loop) playerctl loop none;;
*) cat << EOF
lmc: cli music interface for pulse for those with divine intellect too
grand to remember the pamixer commands.
Allowed options:
up NUM Increase volume (5% default)
down NUM Decrease volume (5% default)
mute Mute microphone
unmute Unmute microphone
deaf Deaf sound
undeaf Undeaf sound
deaf_toggle Toggle between deaf and undeaf
mute_toggle Toggle between mute and unmute
previous Play previous song in player
playpause Toggle play or pause in player
next Play next song in player
mute mute microphone
unmute unmute microphone
deaf deaf sound
undeaf undeaf sound
previous play previous song in player
playpause toggle play or pause in player
next play next song in player
all else Print this message
EOF
esac
pkill -RTMIN+4 $STATUSBAR
sleep 1 && pkill -RTMIN+9 $STATUSBAR

View File

@ -0,0 +1,10 @@
#!/bin/sh
if amixer get Capture | tail -2 | grep -q '\[on\]'; then
lmc mute
lmc undeaf
paplay ~/.local/bin/etc/sxhkd/audio/mic_muted.wav
else
lmc unmute
lmc undeaf
paplay ~/.local/bin/etc/sxhkd/audio/mic_activated.wav
fi

View File

@ -0,0 +1,10 @@
#!/bin/sh
if amixer get Master | tail -2 | grep -q '\[on\]'; then
notify-send -u low 'sxhkd' 'Sound muted\nMicrophone muted'
lmc mute
lmc deaf
else
lmc mute
lmc undeaf
paplay ~/.local/bin/etc/sxhkd/audio/sound_resumed.wav
fi

View File

@ -8,4 +8,4 @@ extern=HDMI2
(xrandr | grep "$extern disconnected")
(xrandr --listactivemonitors | grep $extern) || ((xrandr --output $extern --right-of $intern --auto && setbg) & exit)
(xrandr --listactivemonitors | grep $extern) && xrandr --output $extern --off
background_set
setbg

View File

@ -36,7 +36,7 @@ export NOTMUCH_CONFIG="${XDG_CONFIG_HOME}/notmuch-config"
export NPM_CONFIG_USERCONFIG="${XDG_CONFIG_HOME}/npm/npmrc"
export NUGET_PACKAGES="${XDG_CACHE_HOME}/nugetpackages"
export PASSWORD_STORE_DIR="${XDG_DATA_HOME}/pass"
export SUDO_ASKPASS="${HOME}/.local/bin/tools/pw_menu"
export SUDO_ASKPASS="${HOME}/.local/bin/tools/dmenupass"
export TMUX_TMPDIR="${XDG_CACHE_HOME}/tmux"
export WGETRC="${XDG_CONFIG_HOME}/wgetrc"
export ZDOTDIR="${XDG_CONFIG_HOME}/zsh"

View File

@ -7,7 +7,7 @@ xrandr --auto
[ -f "$HOME/.config/xorg/xdefaults" ] && xrdb -merge "$HOME/.config/xorg/xdefaults" # global resources
[ -f "$HOME/.config/xorg/xpcspec" ] && xrdb -merge "$HOME/.config/xorg/xpcspec" # local resources
background_set
setbg
csum=""
new_csum=$(sha1sum $(which dwm))