Skip to content

Commit f2ec756

Browse files
committed
fix: resolve GitHub Actions expression syntax error
- Fix invalid expression syntax for deleted_files_json in cross-references step - Add proper fallback handling for missing deleted_files_json - Add deleted_files_json to action outputs for proper propagation
1 parent a918566 commit f2ec756

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

.github/docs/actions/docs-core/action.yaml

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,6 +78,9 @@ outputs:
7878
changed_files:
7979
description: 'JSON array of changed documentation files'
8080
value: ${{ steps.file-detection.outputs.changed_files_json }}
81+
deleted_files_json:
82+
description: 'JSON array of deleted documentation files'
83+
value: ${{ steps.file-detection.outputs.deleted_files_json || '[]' }}
8184
formatted_changed_files:
8285
description: 'Markdown-formatted list of changed files with links'
8386
value: ${{ steps.docs-analysis.outputs.formatted_files || '' }}
@@ -870,7 +873,7 @@ runs:
870873
echo "::group::Cross-reference checking"
871874
872875
CHANGED_FILES_JSON='${{ steps.file-detection.outputs.changed_files_json }}'
873-
DELETED_FILES_JSON='${{ steps.file-detection.outputs.deleted_files_json || "[]" }}'
876+
DELETED_FILES_JSON='${{ steps.file-detection.outputs.deleted_files_json }}'
874877
MANIFEST_CHANGED="${{ steps.file-detection.outputs.manifest_changed }}"
875878
DOCS_DIR="${{ inputs.docs-dir }}"
876879
@@ -1028,6 +1031,11 @@ runs:
10281031
BROKEN_IMAGES=0
10291032
TOTAL_REFS=0
10301033
1034+
# Set default value for DELETED_FILES_JSON if not provided
1035+
if [ -z "$DELETED_FILES_JSON" ]; then
1036+
DELETED_FILES_JSON="[]"
1037+
fi
1038+
10311039
# 1. Check for references to deleted files
10321040
if [ "$DELETED_FILES_JSON" != "[]" ] && [ -n "$DELETED_FILES_JSON" ]; then
10331041
echo "Checking for references to deleted files..."

0 commit comments

Comments
 (0)