Last active
December 6, 2024 12:49
-
-
Save izzqz/1ab7d78d2afdb62fe97b602eb8631908 to your computer and use it in GitHub Desktop.
This script parses the i3bar protocol and outputs it as a single line. It's for using i3-style bars like i3status-rust in dwm or similar window managers
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| # To use this pipe i3bar to stdin | |
| # Example i3stauts-rs | ./i3bar-parse.sh | |
| while read line; do | |
| echo "$line" | jq -r '.[].full_text' 2>/dev/null | tr '\n' ' ' | grep -v '^$' | |
| done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment