-
Notifications
You must be signed in to change notification settings - Fork 1
38 lines (33 loc) · 1.23 KB
/
_example.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
on:
workflow_call:
secrets:
EXAMPLE_DEPLOY_KEY:
required: true
jobs:
update:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
# Need this to get version number from last tag
fetch-depth: 0
- name: Regenerate example
run: |
pipx run copier copy --data-file example-answers.yml --trust --vcs-ref=HEAD . example
- name: Rewrite copier answers
run: |
sed -i 's|_src_path: .|_src_path: gh:epics-containers/ioc-template|' example/.copier-answers.yml
- name: remove submodule
run: |
rm -fr example/ibek-support
- name: Publish example
# We pin to the SHA, not the tag, for security reasons.
# https://docs.github.com/en/actions/learn-github-actions/security-hardening-for-github-actions#using-third-party-actions
uses: peaceiris/actions-gh-pages@4f9cc6602d3f66b9c108549d475ec49e8ef4d45e # v4.0.0
with:
deploy_key: ${{ secrets.EXAMPLE_DEPLOY_KEY }}
publish_dir: example
external_repository: epics-containers/ioc-template-example
publish_branch: main
exclude_assets: '' # default would exclude .github