mirror of
https://github.com/boxpositron/absolute-dotfiles.git
synced 2026-10-24 08:23:19 +00:00
feat(omo): notify this Mac about omo sessions on flowstate-remote
mosh drops the OSC 777 banner that omo-notify posts, so omo sessions on the server only reached the phone through ntfy. The server's omo-notify now writes the session state into its tmux client's terminal title (omo:<state>:<time>:<project>), which mosh and ssh carry. A pane-title-changed hook hands it to the new omo-remote, which runs omo-notify for the local mosh pane through the new OMO_NOTIFY_PANE override, so remote sessions get the same sound, tab marker and banner as local ones. Sessions that no terminal is showing come through ntfy instead: omo-remote install starts a launchd agent running ntfy subscribe, which plays the sound and posts the banner for omo pushes the server did not tag attached. Brewfile gains ntfy; the token lives in ~/.config/ntfy/omo-remote.env, outside the repository.
This commit is contained in:
@@ -68,6 +68,9 @@ set -g set-titles on
|
||||
# focusing the tab clears the attention markers.
|
||||
set -g set-titles-string "#{?@omo_status,#{@omo_status} ,}#{session_name}"
|
||||
set-hook -g client-focus-in 'run-shell -b "~/.local/bin/omo-status focus #{q:hook_client}"'
|
||||
# omo on a remote server reports its state in the title of a mosh or ssh pane
|
||||
# ("omo:<state>:..."); omo-remote turns that into the same ding, marker and banner.
|
||||
set-hook -g pane-title-changed 'if -F "#{&&:#{m:*omo:*,#{pane_title}},#{||:#{==:#{pane_current_command},mosh-client},#{==:#{pane_current_command},ssh}}}" "run-shell -b \"~/.local/bin/omo-remote title #{hook_pane}\""'
|
||||
|
||||
# Set plugin manager path before loading plugins
|
||||
set-environment -g TMUX_PLUGIN_MANAGER_PATH "$HOME/.tmux/plugins"
|
||||
|
||||
Reference in New Issue
Block a user