mirror of
https://github.com/moparisthebest/xeps
synced 2024-11-21 08:45:04 -05:00
for #1240: Integrate XEP validation in CI
Adds a Github workflow that executes `tools/validate-xep0001-conformance.sh` against any changed XEP that was changed in a pull request.
This commit is contained in:
parent
7eaa3962a8
commit
286717f769
35
.github/workflows/xep-validation.yml
vendored
Normal file
35
.github/workflows/xep-validation.yml
vendored
Normal file
@ -0,0 +1,35 @@
|
||||
name: XEP validation
|
||||
|
||||
on:
|
||||
pull_request:
|
||||
branches:
|
||||
- master
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
name: Validate any XEP changes
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
with:
|
||||
fetch-depth: 0
|
||||
|
||||
- name: Detect changes to XEP files
|
||||
id: changed-xeps
|
||||
uses: tj-actions/changed-files@v34
|
||||
with:
|
||||
files: |
|
||||
xep-*.xml
|
||||
inbox/*
|
||||
|
||||
- name: Validate changed file(s)
|
||||
if: steps.changed-xeps.outputs.any_changed == 'true'
|
||||
run: |
|
||||
sudo apt-get install -y libxml2-utils
|
||||
result=0
|
||||
for xep in "${{ steps.changed-xeps.outputs.all_changed_files }}"; do
|
||||
if ! tools/validate-xep0001-conformance.sh "$xep"; then
|
||||
result=1
|
||||
fi
|
||||
done
|
||||
exit $result
|
Loading…
Reference in New Issue
Block a user