Status Bar Integration Troubleshooting
General Issues
No Status Showing
Problem
The status bar does not display any tomat status.
Solution
-
Ensure daemon is running:
tomat daemon status # Should show "Daemon is running" -
Check that the PATH includes the directory where tomat is installed. See https://github.com/jolars/tomat/issues/21 for instance.
Waybar Integration Issues
Status Not Updating
Problem
Waybar shows outdated or no tomat status.
Solution
-
Check daemon status:
tomat daemon status # Should show "Daemon is running" -
Test status command directly:
tomat status # Should return JSON with current status -
Check waybar configuration:
{ "custom/tomat": { "exec": "tomat status", "interval": 1, // Update every second "return-type": "json" // Required for proper parsing } } -
Restart waybar:
killall waybar && waybar &
JSON Parsing Errors
Problem
Waybar shows parsing errors for tomat output.
Solution
-
Verify JSON output:
tomat status | jq . # Should show properly formatted JSON -
Check for daemon errors:
tomat daemon stop tomat daemon run # Run in foreground to see errors -
Update waybar config:
{ "custom/tomat": { "exec": "tomat status 2>/dev/null || echo '{\"text\":\"🍅 Error\"}'", "return-type": "json" } }
Styling Not Applied
Problem
Waybar shows tomat status but CSS styling doesn’t work.
Solution
-
Check CSS class names:
tomat status | jq .class # Should return: "work", "work-paused", "break", etc. -
Verify CSS selectors in waybar style:
#custom-tomat.work { background-color: #ff6b6b; } #custom-tomat.work-paused { background-color: #ff9999; } -
Test with simple styling:
#custom-tomat { background-color: red; /* Should always apply */ }