mirror of
https://github.com/OpenTTD/OpenTTD
synced 2026-01-26 21:54:22 +01:00
Codechange: Add GitHub workflow that checks descriptions of source files.
This commit is contained in:
27
.github/workflows/file-descriptions.yml
vendored
Normal file
27
.github/workflows/file-descriptions.yml
vendored
Normal file
@@ -0,0 +1,27 @@
|
||||
name: File descriptions
|
||||
|
||||
on:
|
||||
pull_request:
|
||||
|
||||
concurrency:
|
||||
group: ${{ github.workflow }}-${{ github.ref }}
|
||||
cancel-in-progress: ${{ github.ref != 'refs/heads/master' }}
|
||||
|
||||
jobs:
|
||||
file-descriptions:
|
||||
name: File descriptions
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v6
|
||||
|
||||
- name: Get pull-request commits
|
||||
uses: OpenTTD/actions/checkout-pull-request@v6
|
||||
|
||||
- name: Check descriptions of source files
|
||||
run: |
|
||||
git diff-tree --no-commit-id --name-only -r HEAD HEAD^ > modified_files.txt
|
||||
cat modified_files.txt
|
||||
set -ex
|
||||
python3 .github/file-descriptions.py modified_files.txt
|
||||
Reference in New Issue
Block a user