forked from publicsuffix/list
-
Notifications
You must be signed in to change notification settings - Fork 0
47 lines (40 loc) · 1.49 KB
/
tld-update.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
# Put this automation on hold, until it is able to ignore changes that only update the header timestamp.
name: tld-update
on:
workflow_dispatch:
schedule:
# Run once a day at 15:00 UTC
- cron: '0 15 * * *'
jobs:
psl-gtld-update:
name: Check for TLD data updates
runs-on: ubuntu-latest
steps:
- name: Check out code
uses: actions/checkout@v3
- name: Set up Go
uses: actions/setup-go@v3
with:
go-version: '^1.15'
- name: Run unit tests
run: go test tools/*.go
- name: Set current date
id: get-date
run: echo "NOW=$(date +'%Y-%m-%dT%H:%M:%S %Z')" >> $GITHUB_OUTPUT
- name: Run patchnewgtlds
run: tools/patchnewgtlds
- name: Create pull-request
id: cpr
uses: peter-evans/create-pull-request@v4
with:
commit-message: "util: gTLD data autopull updates for ${{ steps.get-date.outputs.NOW }}"
title: "util: gTLD autopull updates for ${{ steps.get-date.outputs.now }}"
body: "Public suffix list gTLD data updates from `tools/patchnewgtlds` for ${{ steps.get-date.outputs.now }}."
committer: "GitHub <noreply@github.com>"
author: "GitHub <noreply@github.com>"
branch: psl-gtld-update
delete-branch: true
- name: Check outputs
run: |
echo "Pull Request Number - ${{ steps.cpr.outputs.pull-request-number }}"
echo "Pull Request URL - ${{ steps.cpr.outputs.pull-request-url }}"