File tree Expand file tree Collapse file tree 2 files changed +8
-8
lines changed
ansible/roles/source-repo-sync/tasks Expand file tree Collapse file tree 2 files changed +8
-8
lines changed Original file line number Diff line number Diff line change 1717 cmd : |
1818 gh api \
1919 -H "Accept: application/vnd.github.v3+json" \
20- /repos/{{ owner }}/{{ repository_manifest.name }}/git/ref/heads/{{ community_manifest.branch }}-community-files
20+ /repos/{{ owner }}/{{ repository_manifest.name }}/git/ref/heads/{{ community_manifest.prefix | default("") }}{{ community_manifest. branch }}-community-files
2121 changed_when : false
2222 failed_when : false
2323 register : branch_exists
2828 gh api \
2929 --method DELETE \
3030 -H "Accept: application/vnd.github.v3+json" \
31- /repos/{{ owner }}/{{ repository_manifest.name }}/git/refs/heads/{{ community_manifest.branch }}-community-files
31+ /repos/{{ owner }}/{{ repository_manifest.name }}/git/refs/heads/{{ community_manifest.prefix | default("") }}{{ community_manifest. branch }}-community-files
3232 when : branch_exists.rc == 0
3333
3434 - name : Create working branch # noqa command-instead-of-module
3535 ansible.builtin.shell :
3636 cmd : >
37- git checkout -b {{ community_manifest.branch }}-community-files \
37+ git checkout -b {{ community_manifest.prefix | default("") }}{{ community_manifest. branch }}-community-files \
3838 origin/{{ community_manifest.prefix | default("") }}{{ community_manifest.branch }}
3939 chdir : " {{ staging_path }}/{{ repository_manifest.name }}"
4040 changed_when : true
6565
6666 - name : Push branch to remote # noqa command-instead-of-module command-instead-of-shell no-handler
6767 ansible.builtin.shell :
68- cmd : " git push -u origin {{ community_manifest.branch }}-community-files"
68+ cmd : " git push -u origin {{ community_manifest.prefix | default('') }}{{ community_manifest. branch }}-community-files"
6969 chdir : " {{ staging_path }}/{{ repository_manifest.name }}"
7070 when : community_copy.changed | bool
7171
Original file line number Diff line number Diff line change 1717 cmd : |
1818 gh api \
1919 -H "Accept: application/vnd.github.v3+json" \
20- /repos/{{ owner }}/{{ repository_manifest.name }}/git/ref/heads/{{ workflow_manifest.branch }}-workflows
20+ /repos/{{ owner }}/{{ repository_manifest.name }}/git/ref/heads/{{ workflow_manifest.prefix | default("") }}{{ workflow_manifest. branch }}-workflows
2121 changed_when : false
2222 failed_when : false
2323 register : working_branch_exists
2828 gh api \
2929 --method DELETE \
3030 -H "Accept: application/vnd.github.v3+json" \
31- /repos/{{ owner }}/{{ repository_manifest.name }}/git/refs/heads/{{ workflow_manifest.branch }}-workflows
31+ /repos/{{ owner }}/{{ repository_manifest.name }}/git/refs/heads/{{ workflow_manifest.prefix | default("") }}{{ workflow_manifest. branch }}-workflows
3232 when : working_branch_exists.rc == 0
3333
3434 - name : Create working branch # noqa command-instead-of-module
3535 ansible.builtin.shell :
3636 cmd : >
37- git checkout -b {{ workflow_manifest.branch }}-workflows \
37+ git checkout -b {{ workflow_manifest.prefix | default("") }}{{ workflow_manifest. branch }}-workflows \
3838 origin/{{ workflow_manifest.prefix | default("") }}{{ workflow_manifest.branch }}
3939 chdir : " {{ staging_path }}/{{ repository_manifest.name }}"
4040 changed_when : true
8484
8585 - name : Push branch to remote # noqa command-instead-of-module command-instead-of-shell no-handler
8686 ansible.builtin.shell :
87- cmd : " git push -u origin {{ workflow_manifest.branch }}-workflows"
87+ cmd : " git push -u origin {{ workflow_manifest.prefix | default('') }}{{ workflow_manifest. branch }}-workflows"
8888 chdir : " {{ staging_path }}/{{ repository_manifest.name }}"
8989 changed_when : true
9090
You can’t perform that action at this time.
0 commit comments