Skip to content

Commit 312f5cb

Browse files
committed
Write the aviaryui state to /tmp
Aids in debugging what the expected remote state is when controlling streaming laptops remotely.
1 parent 9542a71 commit 312f5cb

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

apps/aviaryui/src/main.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -117,6 +117,11 @@ def on_toggle_livestream_action(self, *args):
117117
# TODO figure out how to just bind this to a toggle
118118
# And not do this stupid shit
119119
new_state = not action.get_state()
120+
# TODO do an async I/O call
121+
# Caution for development: this file gets written to the Flatpak's /tmp!
122+
# Don't be surprised if you don't see this file in the host /tmp.
123+
with open('/tmp/aviaryui-state', 'w+') as f:
124+
f.write(str(new_state) + '\n')
120125
action.change_state(GLib.Variant.new_boolean(new_state))
121126

122127
status_label = self.props.active_window.status_label

0 commit comments

Comments
 (0)