-
Notifications
You must be signed in to change notification settings - Fork 43
37 lines (33 loc) · 1.28 KB
/
check-copyright.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
name: Check copyright
on:
push:
pull_request:
types: [opened, synchronize, reopened]
permissions: write-all
concurrency:
group: copyright-${{ github.ref }}
cancel-in-progress: true
jobs:
check-copyright:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3.5.3
- name: Check copyright
uses: ./.github/actions/check-copyright
- name: Comment
if: failure() && github.event_name == 'pull_request'
uses: thollander/actions-comment-pull-request@dadb7667129e23f12ca3925c90dc5cd7121ab57e
continue-on-error: true # if we are in a fork, this will fail, but we don't care (tables will be missing)
with:
comment_tag: 'copyright'
mode: 'recreate'
message: |
:exclamation: Please run `./gradlew spotlessApply` on your branch to fix copyright headers.
- name: Delete Comment
if: github.event_name == 'pull_request'
uses: thollander/actions-comment-pull-request@dadb7667129e23f12ca3925c90dc5cd7121ab57e
continue-on-error: true # if we are in a fork, this will fail, but we don't care (tables will be missing)
with:
comment_tag: 'copyright'
mode: 'delete'