fix(sketchybar): drop the aerospace leftovers and the stale brew service label - #165
Merged
Conversation
…ice label aerospace was removed in #125 but the sketchybar helpers still called /opt/homebrew/bin/aerospace. wm.sh fell back to that binary whenever OmniWM was not running, so instead of failing it quietly returned nothing and the bar went blank; refresh-displays.sh depended on it outright and could not work at all. Also two labels that #161 invalidated: `just restart sketchybar` and app_guard's restart command still pointed at homebrew.mxcl.sketchybar, which no longer exists now that the agent is org.nix-community.home.sketchybar. Puddle is added to the app_guard list — it had silently not been running, which is exactly what that list is for. Kept as-is: the aerospace_workspace_change event name, the AEROSPACE_* env vars and /tmp/sketchybar-aero-display.map. They are consistent between the firing side and the reading side, so renaming changes no behaviour and only widens the diff.
Event aerospace_workspace_change -> omniwm_workspace_change, AEROSPACE_* -> OMNIWM_*, /tmp/sketchybar-aero-display.map -> sketchybar-omniwm-display.map. Both the firing side (omniwm-event.sh) and every reading side are renamed in the same commit; a half rename would leave the event reaching nobody.
gapul
added a commit
that referenced
this pull request
Aug 8, 2026
#165's rename touched the same comment block that this branch deletes; keeping the deletion.
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
sketchybar を launchd 化した後の起動確認で、aerospace の残骸が動いているのを見つけたので掃除した。
実害があったもの
helpers/wm.shは OmniWM が動いていなければ/opt/homebrew/bin/aerospaceにフォールバックする作りだった。aerospace は #125 で撤去済みでバイナリは存在しないので、この経路に入ると全照会が空を返す。エラーにもならず、バーが黙って無表示になるだけ。フォールバック分岐ごと落とした。helpers/refresh-displays.shは最初から最後まで aerospace 依存で、ディスプレイを抜き差ししたあとに叩く手動コマンドがそもそも動かない状態だった。wm.sh 経由に付け替えた(wm_list_monitors_by_xを追加。display_watch.sh に同じロジックが埋まっていたのでそこも共有させた)。#161 が置いていったもの
just restart sketchybarと app_guard の再起動コマンドがhomebrew.mxcl.sketchybarを指したままだった。launchd 化でこのラベルは消えたのでorg.nix-community.home.sketchybarに直した。自分の PR の後始末。ついでに
Puddle が黙って起動していなかった(プロセスなし・クラッシュログなし、ただ落ちていただけ)。app_guard の監視対象はまさにこういうやつのためにあるので追加した。
残したもの
イベント名
aerospace_workspace_change、AEROSPACE_*環境変数、/tmp/sketchybar-aero-display.map。発火側の omniwm-event.sh と受け側で名前が一貫していて、改名しても挙動は1ミリも変わらず、読み書き両側を触る差分だけが増える。気持ち悪いのは分かるが今回は見送った。検証
bash -n3ファイル、just fmt(shellcheck 含む)Passwm_list_monitors_by_x→ 1、wm_focused_workspace→ 4、wm_workspace_apps→ Google Chromerefresh-displays.shを実走。マップ生成(1:1)、launchctl kickstart での再起動、再起動後も sketchybar が生存しているところまで確認