I volnoti verwenden, einen Benachrichtigungsdienst, zusammen mit meinem i3 Window-Manager, in meiner i3config Datei Ich habe versucht, die Befehle für volnoti wie folgt umzusetzen:Shell-Befehl funktioniert nicht
# Pulse Audio controls
# Increase sound volume
bindsym XF86AudioRaiseVolume exec --no-startup-id pactl set-sink-volume 1 +5% && pkill -RTMIN+1 i3blocks && volnoti-show $(amixer -c 1 -M -D pulse get Master | grep -o '[0-9]*%' -m 1 | grep -o '[0-9]*')
# Decrease sound volume
bindsym XF86AudioLowerVolume exec --no-startup-id pactl set-sink-volume 1 -5% && pkill -RTMIN+1 i3blocks && volnoti-show $(amixer -c 1 -M -D pulse get Master | grep -o '[0-9]*%' -m 1 | grep -o '[0-9]*')
# Mute sound
bindsym XF86AudioMute exec --no-startup-id pactl set-sink-mute 1 toggle && pkill -RTMIN+1 i3blocks && if [[ -n $(amixer -c 1 -M -D pulse get Master | grep '\[off\]' -m 1) ]]; then volnoti-show -m; else volnoti-show $(amixer -c 1 -M -D pulse get Master | grep -o '[0-9]*%' -m 1 | grep -o '[0-9]*'); fi
Erhöhen und Erniedrigen gezeigt ohne Probleme, aber wenn ich den Ton i3 Protokolle dieser Fehler stumm:
ERROR: Could not translate string to key symbol: "split+h"
[libi3] ERROR: Surface 0x555ee0dfd3b0 is not initialized, skipping drawing.
[libi3] ERROR: Surface 0x555ee0dfd3b0 is not initialized, skipping drawing.
[libi3] ERROR: Surface 0x555ee0dfd3b0 is not initialized, skipping drawing.
ERROR: Received ConfigureNotify for unknown window 0x00800000
ERROR: Received ExposeEvent for unknown window 0x00800000
ERROR: Received ConfigureNotify for unknown window 0x00800000
ERROR: Received ConfigureNotify for unknown window 0x00800003
ERROR: Received ConfigureNotify for unknown window 0x00800003
ERROR: Received ConfigureNotify for unknown window 0x00800006
ERROR: Received ConfigureNotify for unknown window 0x00800006
ERROR: Received ConfigureNotify for unknown window 0x00800009
ERROR: Received ConfigureNotify for unknown window 0x00800009
ERROR: Received ConfigureNotify for unknown window 0x0080000c
ERROR: Received ConfigureNotify for unknown window 0x0080000c
ERROR: Expected one of these tokens: <end>, '[', 'move', 'exec', 'exit', 'restart', 'reload', 'shmlog', 'debuglog', 'border', 'layout', 'append_layout', 'workspace', 'focus', 'kill', 'open', 'fullscreen', 'sticky', 'split', 'floating', 'mark', 'unmark', 'resize', 'rename', 'nop', 'scratchpad', 'title_format', 'mode', 'bar'
ERROR: Your command: exec --no-startup-id pactl set-sink-mute 1 toggle && pkill -RTMIN+1 i3blocks && "if [[ -n $(amixer -c 1 -M -D pulse get Master | grep '\[off\]' -m 1) ]]; then volnoti-show -m; else volnoti-show $(amixer -c 1 -M -D pulse get Master | grep -o '[0-9]*%' -m 1 | grep -o '[0-9]*'); fi"
ERROR: ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
ich muss zugeben, es ist nicht die eleganteste Lösung. Aber es funktioniert, bis auf die letzte Zeile. Wenn ich den letzten Teil direkt in einem Terminal ausführen, es funktioniert gut und stumm ist richtig erkannt:
if [[ -n $(amixer -c 1 -M -D pulse get Master | grep '\[off\]' -m 1) ]]; then volnoti-show -m; else volnoti-show $(amixer -c 1 -M -D pulse get Master | grep -o '[0-9]*%' -m 1 | grep -o '[0-9]*'); fi
können Sie bitte den Downvote erklären? – Jonas