-
Notifications
You must be signed in to change notification settings - Fork 1.7k
39 lines (37 loc) · 1.65 KB
/
changelog.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
#
# This action checks PRs to see if any CHANGELOG* files were updated.
# If none were, it will add a message to the PR asking if it would make sense to do so.
#
name: Changelog
on: pull_request
jobs:
changelog:
# For security reasons, GITHUB_TOKEN is read-only on forks, so we cannot leave comments on PRs.
# This check skips the job if it is detected we are running on a fork.
if: ${{ github.event.pull_request.head.repo.full_name == 'smartcontractkit/chainlink' }}
name: Changelog checker
runs-on: ubuntu-latest
steps:
- name: Check for changed files
id: changedfiles
uses: umani/changed-files@0239328a3a6268aad16af7c3e4efc78e32d6c0f0 # Version 4.0.1
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
pattern: '^docs/CHANGELOG.*$'
- name: Make a comment
uses: unsplash/comment-on-pr@ffe8f97ccc63ce12c3c23c6885b169db67958d3b # Version 1.3.0
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
if: contains(steps.changedfiles.outputs.files_updated, 'CHANGELOG') != true && contains(steps.changedfiles.outputs.files_created, 'CHANGELOG') != true
with:
msg: "I see that you haven't updated any CHANGELOG files. Would it make sense to do so?"
check_for_duplicate_msg: true
- name: Collect Metrics
if: always()
id: collect-gha-metrics
uses: smartcontractkit/push-gha-metrics-action@90fcbaac8ebf86da9c4d55dba24f6fe3029f0e0b
with:
basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }}
hostname: ${{ secrets.GRAFANA_CLOUD_HOST }}
this-job-name: Changelog checker
continue-on-error: true