def go(): davinci = Davinci() if davinci.resolve is None: return davinci.get_current_project() if davinci.project is None: print('Could not get current DaVinci project') return flo = VideoFlo() project_name = davinci.project.GetName() channel = flo.get_channel(project_name) if channel is None: return idea = Idea() idea.from_project(project_name, channel) if not idea.exists(): print('Directory for {} not found'.format(project_name)) return args = flo.get_finish_edit_arguments() if not args.offline: trello = Trello() if not trello.lists_exist(['Render'], idea.channel): return success = trello.move_card(idea, 'Render') if not success: return davinci.export_project(idea) update_tag('Render', idea.path)
def go(): flo = VideoFlo() idea = Idea() idea.read_user_input(flo) if not idea.exists(): print('Directory for {} not found'.format(idea.name)) return davinci = Davinci() if davinci.resolve is None: return davinci.set_project_manager() if davinci.project_manager is None: return is_new = davinci.open_project(idea) if davinci.project is None: return if is_new: davinci.import_timeline() davinci.workspace_setup() davinci.import_files() if not idea.offline: trello = Trello() if not trello.lists_exist(['Finish'], idea.channel): return success = trello.move_card(idea, 'Finish') if not success: return update_tag('Finish', idea.path)
def go(): flo = VideoFlo() args = flo.get_init_arguments() channel = Channel(flo.config, args.channel) trello = Trello() if not trello.lists_exist(STAGES, channel, create=True): return trello.add_custom_fields(channel)
def go(): flo = VideoFlo() args = flo.get_upload_arguments() channel = Channel(flo.config, args.channel) dry_run = args.dry_run limit = args.limit if args.limit > 0 else 0 if limit > 0: print("Limiting to {} video upload(s)".format(limit)) trello = Trello() if not trello.lists_exist(['Upload', 'Scheduled'], channel): return upload_dict = get_upload_dict(channel, trello, limit) if not dry_run and len(upload_dict) > 0: do_uploads(upload_dict)
def go(): flo = VideoFlo() idea = Idea() idea.read_user_input(flo) if not idea.exists(): print('Directory for {} not found'.format(idea.name)) return if not idea.offline: trello = Trello() if not trello.lists_exist(['Edit'], idea.channel): return success = trello.move_card(idea, 'Edit') if not success: return idea.copy_screen_recordings(flo) update_tag('Edit', idea.path)
def go(): flo = VideoFlo() args = flo.get_render_arguments() channel = Channel(flo.config, args.channel) trello = Trello() renderable = _get_render_list(channel, trello, args) if renderable is None or len(renderable) == 0: print('Nothing to render') return loop(channel, trello, args, renderable)
def do_uploads(upload_dict): upload_count = 0 upload_total = len(upload_dict) start_time = datetime.now() for card_id, video in upload_dict.items(): print('Starting upload for {}'.format(video.file)) video_id = video.upload() if video_id is not None: upload_count += 1 update_tag('Scheduled', video.path) trello = Trello() trello.move_card(video.idea, 'Scheduled') trello.attach_links_to_card(card_id, video_id) duration = datetime.now() - start_time print('Uploaded {}/{} videos in {}'.format(upload_count, upload_total, duration))
def go(): flo = VideoFlo() idea = Idea() idea.read_user_input(flo) trello = Trello() if not idea.offline: if not trello.lists_exist(['Script'], idea.channel): return card_id, board_id = trello.make_card(idea) if card_id is None or board_id is None: return if not trello.add_filename_to_card(card_id, board_id, idea.name): trello.delete_card(card_id) return idea_directory = idea.make_directory() if idea_directory is None: if not idea.offline: trello.delete_card(card_id) return idea.make_files() idea.make_directories() if not idea.offline: trello.save_card(card_id, idea) add_tag('Script', idea.path, do_open=True)