-
Notifications
You must be signed in to change notification settings - Fork 309
48 lines (41 loc) · 1.24 KB
/
fetch-obsolete-pages.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
47
48
name: "WikiMedia - Fetch the list of obsolete pages"
on:
# Run on cron, daily at 5:30am UTC.
schedule:
- cron: '30 5 * * *'
# Run on request.
workflow_dispatch:
inputs:
debug:
type: boolean
required: false
description: 'Set the debug mode'
jobs:
run:
# Only run on the canonical repository.
if: github.repository == 'moodle/devdocs'
name: Update obsoletions and migrations with Wikimedia
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v3
with:
node-version: 16.x
cache: yarn
- name: Install dependencies
run: yarn install --frozen-lockfile
- name: Run update script
run: yarn wikimedia-sync fetch-obsolete
env:
DEBUG: ${{ github.event.inputs.debug }}
WIKIMEDIA_DEBUG: ${{ github.event.inputs.debug }}
- name: Create Pull Request
uses: peter-evans/create-pull-request@v4
with:
add-paths: |
data/*.json
commit-message: "[repo] Update list of obsolete pages"
title: "[repo] Update list of obsolete pages"
branch: obsolete-legacy-page-list
signoff: false
delete-branch: true