Преглед изворни кода

Make sure showgbr module in i3staplus does not break JSON syntax

Alois Mahdal пре 1 година
родитељ
комит
f4d7897068
1 измењених фајлова са 1 додато и 1 уклоњено
  1. 1
    1
      dotfiles/config/i3/bin/i3staplus

+ 1
- 1
dotfiles/config/i3/bin/i3staplus Прегледај датотеку

57
 
57
 
58
 gibrs() {
58
 gibrs() {
59
     local out
59
     local out
60
-    out=$(showgbr)
60
+    out=$(showgbr | head -1 | sed 's/"/\\"/')
61
     test -n "$out" || return 0
61
     test -n "$out" || return 0
62
     printf '{"full_text": "ⓖ %s"},' \
62
     printf '{"full_text": "ⓖ %s"},' \
63
        "$out"
63
        "$out"