def update(self): if ProcessCache.empty(): return self.erase() status_bar_tasks = self.settings.get('status_bar_tasks', False) if status_bar_tasks: task_names = set([process.get_task_name() for process in ProcessCache.get()]) if status_bar_tasks != True: if not isinstance(status_bar_tasks, list): status_bar_tasks = [status_bar_tasks] task_names = task_names.intersection(set(status_bar_tasks)) if task_names: defer_sync(lambda: self.set(', '.join(task_names)))
def run_process(self, task): process = CrossPlatformProcess(self.working_dir) process.run(task) stdout, stderr = process.communicate(self.append_to_output_view_in_main_thread) defer_sync(lambda: self.finish(stdout, stderr))
def show_quick_panel(self, items, on_done=None, font=sublime.MONOSPACE_FONT): defer_sync(lambda: self.window.show_quick_panel(items, on_done, font))
def append_to_output_view_in_main_thread(self, text): defer_sync(lambda: self.append_to_output_view(text))
def run_process(self, task): process = CrossPlatformProcess(self.working_dir) process.run(task) stdout, stderr = process.communicate( self.append_to_output_view_in_main_thread) defer_sync(lambda: self.finish(stdout, stderr))