forked from docs/doc-exports
Update .gitea/workflows/yaml-lint.yml
This commit is contained in:
@ -77,18 +77,19 @@ jobs:
|
||||
run: |
|
||||
set -e
|
||||
|
||||
BASE_SHA="${{ gitea.event.pull_request.base.sha }}"
|
||||
# BASE_SHA="${{ gitea.event.pull_request.base.sha }}"
|
||||
|
||||
echo "Base SHA: $BASE_SHA"
|
||||
# echo "Base SHA: $BASE_SHA"
|
||||
|
||||
# Fetch base branch so git diff works in PRs
|
||||
git fetch origin "$BASE_SHA"
|
||||
# git fetch origin "${{ gitea.base_ref }}"
|
||||
# # Fetch base branch so git diff works in PRs
|
||||
# git fetch origin "$BASE_SHA"
|
||||
# # git fetch origin "${{ gitea.base_ref }}"
|
||||
|
||||
# Get changed YAML files
|
||||
files=$(git diff --name-only "$BASE_SHA"...HEAD \
|
||||
| grep -E '\.(yml|yaml)$' || true)
|
||||
# # Get changed YAML files
|
||||
# files=$(git diff --name-only "$BASE_SHA"...HEAD \
|
||||
# | grep -E '\.(yml|yaml)$' || true)
|
||||
|
||||
files="${{ steps.changed-files.outputs.changed_files }}"
|
||||
if [ -z "$files" ]; then
|
||||
echo "No YAML files changed"
|
||||
exit 0
|
||||
|
||||
Reference in New Issue
Block a user