Adrià Vilanova Martínez | 83045cb | 2024-11-09 13:50:25 +0100 | [diff] [blame] | 1 | # This file is only used for tests, but Copybara won't work unless it exists. |
| 2 | - name: "Create dummy test_repos_config.sky" |
| 3 | ansible.builtin.copy: |
| 4 | src: "{{ zuul.project.src_dir }}/.copybara/test_repos_config.bara.sky.template" |
| 5 | dest: "{{ zuul.project.src_dir }}/.copybara/test_repos_config.bara.sky" |
| 6 | remote_src: true |
| 7 | force: true |
| 8 | |
Adrià Vilanova Martínez | 82a261b | 2024-11-08 21:26:39 +0100 | [diff] [blame] | 9 | - name: "Run Copybara migration" |
| 10 | ansible.builtin.shell: |
| 11 | cmd: "sh export-commits.sh" |
| 12 | chdir: "{{ zuul.project.src_dir }}/.copybara" |
| 13 | register: result |
| 14 | # Exit status 4 means NO_OP: |
| 15 | # https://github.com/google/copybara/blob/55c4904442bcf905fe03c2297488b90428b472a7/java/com/google/copybara/util/ExitCode.java#L42 |
| 16 | failed_when: result.rc not in [0, 4] |
| 17 | retries: 3 |