MCPcopy Create free account
hub / github.com/debuggyo/Exo / _record_source

Function _record_source

ignis/scripts/recorder.py:71–93  ·  view source on GitHub ↗
(source: str, *args: str, **kwargs)

Source from the content-addressed store, hash-verified

69
70
71def _record_source(source: str, *args: str, **kwargs):
72 global last_recording_path
73
74 if not recorder.is_available:
75 send_notification("No recorder", "gpu-screen-recorder was not found.")
76 return
77
78 if recorder.active:
79 recorder.stop_recording()
80 return
81
82 timestamp = datetime.now().strftime("%Y-%m-%d_%H-%M-%S")
83 file_path = os.path.expanduser(f"~/Videos/recording_{timestamp}.mp4")
84 last_recording_path = file_path
85
86 asyncio.create_task(
87 _start_recording_task(
88 source=source,
89 file_path=file_path,
90 audio_devices=["default_output"] if options.record_audio else None,
91 **kwargs,
92 )
93 )
94
95
96def stop_recording():

Callers 3

record_screenFunction · 0.85
record_portalFunction · 0.85
_record_region_taskFunction · 0.85

Calls 2

send_notificationFunction · 0.90
_start_recording_taskFunction · 0.85

Tested by

no test coverage detected