aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/i3blocks/.local
diff options
context:
space:
mode:
Diffstat (limited to 'i3blocks/.local')
-rwxr-xr-xi3blocks/.local/lib/i3blocks/i3blocks-title6
1 files changed, 3 insertions, 3 deletions
diff --git a/i3blocks/.local/lib/i3blocks/i3blocks-title b/i3blocks/.local/lib/i3blocks/i3blocks-title
index 716f56f..c014adc 100755
--- a/i3blocks/.local/lib/i3blocks/i3blocks-title
+++ b/i3blocks/.local/lib/i3blocks/i3blocks-title
@@ -1,9 +1,9 @@
#!/bin/sh
into_block='{
- "full_text": (.name // ""),
- "short_text": ([.app_id, .window_title, .name] | map(select(. != null and . != "")) | (first // "")),
-} | .short_text |= .[0:(env.max_width // (. | length) | tonumber)]'
+ "full_text": (.name[0:50] // ""),
+ "short_text": ([.app_id, .window_title, .name] | map(select(. != null and . != "")) | (first // "") | .[0:25]),
+}'
swaymsg -t get_tree | jq -c '.. | select(.focused? == true and .type == "con") | '"$into_block"