2022-06-17 02:31:32 +00:00
|
|
|
name: Block app edits
|
|
|
|
|
|
|
|
on: ["pull_request"]
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
block:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v3
|
|
|
|
with:
|
|
|
|
fetch-depth: "2" # To retrieve the preceding commit.
|
|
|
|
|
|
|
|
- name: Get changed files using defaults
|
|
|
|
id: changed-files
|
|
|
|
uses: tj-actions/changed-files@v23
|
|
|
|
- name: List all added files
|
|
|
|
run: |
|
|
|
|
for file in ${{ steps.changed-files.outputs.all_changed_and_modified_files }}; do
|
|
|
|
echo "$file"
|
|
|
|
done
|
|
|
|
|
2022-06-17 03:07:30 +00:00
|
|
|
- name: Block edits in docs/source-app
|
|
|
|
if: contains(steps.changed-files.outputs.all_changed_and_modified_files, 'docs/source-app')
|
2022-06-17 02:31:32 +00:00
|
|
|
run: exit 1
|