blob: d78a00cb6276d92f02c2a401a3debe061411cf49 (
plain) (
blame)
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
47
48
|
name: Jekyll
on:
workflow_call:
workflow_dispatch:
jobs:
maintenance:
strategy:
matrix:
project:
- jekyll-theme
runs-on: ubuntu-latest
name: '${{ matrix.project }}'
env:
GH_TOKEN: '${{ github.token }}'
steps:
- name: Configure SSH
run: |
mkdir -p ~/.ssh
cat > ~/.ssh/config <<'EOF'
StrictHostKeyChecking no
EOF
- name: Set up ssh-agent
uses: webfactory/ssh-agent@v0.9.0
with:
ssh-private-key: '${{ secrets.SSH_KEY }}'
- name: Checkout
run: |
git clone -q 'ssh://git@github.com/egor-tensin/${{ matrix.project }}.git'
- name: find
run: find
- name: Set up Ruby
uses: ruby/setup-ruby@v1
with:
bundler-cache: true
working-directory: '${{ matrix.project }}'
- name: Configure git
run: |
git config --global user.name 'Egor Tensin'
git config --global user.email 'egor@tensin.name'
- name: Run maintenance
run: |
make -C '${{ matrix.project }}' maintenance
- name: Wait until the run is finished
run: |
id="$( gh run list --json databaseId --limit 1 --status completed --jq '.[0].databaseId' )"
gh run watch --repo 'egor-tensin/${{ matrix.project }}' --compact --exit-status "$id"
|