forked from htcondor/htcondor
-
Notifications
You must be signed in to change notification settings - Fork 0
39 lines (33 loc) · 1.33 KB
/
publish_release_to_website.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
39
name: Publish Release To Website
on:
release:
types: [released, edited]
jobs:
Publish-Release-To-Website:
runs-on: ubuntu-latest
env:
publish_path: _data/releases/
publish_branch: master
publish_repo_ssh: [email protected]:htcondor/htcondor-web.git
steps:
- name: Build the release page a put it in current directory
uses: CHTC/build_release_page@master
with:
repository: ${{ github.repository }}
tag_name: ${{ github.event.release.tag_name }}
- name: Setup SSH Keys and known_hosts
uses: webfactory/[email protected]
with:
ssh-private-key: ${{ secrets.HTCONDOR_WEB_DEPLOY_KEY }}
- run: |
mkdir website
git clone ${{ env.publish_repo_ssh }} ./website
cd website
git checkout -b build-release-page origin/${{ env.publish_branch }}
mv ../*.yml ./${{ env.publish_path }} # Move yaml created by the build_release_page action to branch
# Publish the article
git add .
git config user.name "Automatic Release Publish"
git config user.email ""
git commit -am "GHA: Publish Release https://github.com/${{ github.repository }}/releases/tag/${{ github.event.release.tag_name }}"
git push origin build-release-page:${{ env.publish_branch }}