diff options
author | Sacha Chua <sacha@sachachua.com> | 2022-10-31 21:53:15 -0400 |
---|---|---|
committer | Sacha Chua <sacha@sachachua.com> | 2022-10-31 21:53:15 -0400 |
commit | 4696aa1fed214fe1084d7c3deecaaa289bc0a1fd (patch) | |
tree | fa0d7d2d121cfe2787b1f1a94b2328aeff73c724 /roles/caption | |
parent | b8c97d14ed81871eef51ba7253982c45258ec538 (diff) | |
download | emacsconf-ansible-4696aa1fed214fe1084d7c3deecaaa289bc0a1fd.tar.xz emacsconf-ansible-4696aa1fed214fe1084d7c3deecaaa289bc0a1fd.zip |
Update OBS, renamepublish and edit
Diffstat (limited to '')
-rw-r--r-- | roles/caption/tasks/main.yml | 2 | ||||
-rwxr-xr-x | roles/caption/templates/process-captions.py | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/roles/caption/tasks/main.yml b/roles/caption/tasks/main.yml index 3fa997c..c1511cf 100644 --- a/roles/caption/tasks/main.yml +++ b/roles/caption/tasks/main.yml @@ -33,7 +33,7 @@ path: "{{ emacsconf_caption_dir }}" state: directory - name: Copy the script for processing the files - tags: process-captions, wip + tags: process-captions template: src: process-captions.py dest: "{{ emacsconf_caption_dir }}/process-captions.py" diff --git a/roles/caption/templates/process-captions.py b/roles/caption/templates/process-captions.py index da99203..50c62d1 100755 --- a/roles/caption/templates/process-captions.py +++ b/roles/caption/templates/process-captions.py @@ -142,7 +142,7 @@ def generate_captions(work): result = clean_up_timestamps(result) with open(new_file, 'w') as vtt: whisper.utils.write_vtt(result['segments'], file=vtt) - with open(work['base'] + '.txt') + with open(work['base'] + '.txt'): whisper.utils.write_txt(result['segments'], file=txt) work['vtt'] = new_file if 'srv2' in work: del work['srv2'] |