key_layout doesn't work because it doesn't output a \n at the end
Aster89 opened this issue · comments
Enrico Maria De Angelis commented
Given
$ setxkbmap -query
rules: evdev
model: pc105
layout: it
Expected behavior
$ ./key_layout/key_layout | sed -z 's/it\n/YES\n/;s/it/NO\n/'
YES
Actual behavior
$ ./key_layout/key_layout | sed -z 's/it\n/YES\n/;s/it/NO\n/'
NO
i3blocks config relevant to blocklet(s)
Irrelevant.
Output of blocklet(s) when run from command line
With reference to the example above, it
instead of it\n
.
Output of any relevant other commands that might help diagnostics
Enrico Maria De Angelis commented
My fix would be to simply append | sed 's/$/\n/'
to the existing command. Tested and works for me. Gimme a go and I'll PR it.