summaryrefslogblamecommitdiffstats
path: root/roles/prerec/tasks/main.yml
blob: 8144e28200f7937a0248819b9a611181ea1cf79a (plain) (tree)
1
2
3
4
5
6
7
8
9
10
11

                                   
                                                  


                                  




                           
       












                                                 








                                            
                                                   





                                                           
               

                                   
                      

                     
                                     




                                  
          
               
                                
                         
                  
                 
                   
                        









                                                      
- name: Ensure the directory exists
  file:
    path: "{{ emacsconf_caption_dir }}/{{ item }}"
    state: directory
    owner: "{{ emacsconf_user }}"
    group: "{{ emacsconf_group }}"
  loop:
    - scripts
    - cache
    - files
- name: Create the symlinks
  file:
    src: "{{ emacsconf_caption_dir }}/{{ item }}"
    dest: "/home/{{ emacsconf_user }}/{{ item }}"
    owner: "{{ emacsconf_user }}"
    group: "{{ emacsconf_group }}"
    state: link
  loop:
    - scripts
    - cache
    - files
- name: Create the symlinks
  file:
    src: "{{ emacsconf_caption_dir }}"
    dest: "/home/{{ emacsconf_user }}/current"
    owner: "{{ emacsconf_user }}"
    group: "{{ emacsconf_group }}"
    state: link
- name: Add it to the path
  lineinfile:
    line: export PATH=~/scripts:$PATH
    path: /home/{{ emacsconf_user }}/.bashrc
    owner: "{{ emacsconf_user }}"
    group: "{{ emacsconf_group }}"
- name: Recreate encoding script and backup old one
  tags: process-prerec
  template:
    src: "reencode.sh"
    dest: "{{ emacsconf_caption_dir }}/scripts/reencode.sh"
    owner: "{{ emacsconf_user }}"
    group: "{{ emacsconf_group }}"
    backup: yes
    mode: 0775
- name: Copy scripts for processing
  tags: process-prerec
  template:
    src: "{{ item }}"
    dest: "/usr/local/bin/{{ item }}"
    owner: "{{ emacsconf_user }}"
    group: "{{ emacsconf_group }}"
    mode: 0775
  loop:
    - process-prerec.sh
    - talk
    - upload.sh
    - publish-backstage-index.sh
    - update-emacsconf.sh
    - thumbnail.sh
    - reencode.sh
    - run-aeneas.sh
    - rename-original.sh
    - mux-subs.sh
    - verify-main.sh
    - remux.sh
- name: Copy Makefile
  template:
    src: Makefile
    dest: "{{ emacsconf_caption_dir }}/cache/Makefile"
    owner: "{{ emacsconf_user }}"
    group: "{{ emacsconf_group }}"