-
Notifications
You must be signed in to change notification settings - Fork 39
46 lines (42 loc) · 1.43 KB
/
chron-release.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
40
41
42
43
44
45
46
name: "Update Tagged Releases"
on:
schedule:
- cron: "30 8 1 * *"
workflow_dispatch:
jobs:
refresh-modules:
name: Refresh Release Submodules
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
with:
persist-credentials: false
fetch-depth: 0
ref: releases
submodules: recursive
- name: Merge upstream changes to releases branch
run: |
git config --global user.email "[email protected]"
git config --global user.name "GitHub Action"
git merge origin/master --strategy-option theirs || true
git submodule foreach 'git reset HEAD $path'
git submodule foreach 'git checkout `git describe --tags $(git rev-list --tags --max-count=1)`' || true
cd processing/wirecloud/wirecloud
git checkout 1.3.1
cd ../../..
cd third-party/domibus
git checkout 5.0
cd ../..
git add -A .
git commit -m "Merge master into releases" -a
- name: Push changes
uses: ad-m/github-push-action@master
continue-on-error: true
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
branch: releases
force: true
- name: Summarize latest releases
run: |
SUMMARY=$(git submodule -q foreach ' echo $(basename `git rev-parse --show-toplevel`) `git describe --tags $(git rev-list --tags --max-count=1)`' || true)
echo $SUMMARY