Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit5e4cc71

Browse files
committed
fix: correct YAML indentation in heredoc blocks
- All heredoc content must be indented to match bash script context- Prevents YAML parser from interpreting bash script content as YAML keys- Validates successfully with PyYAML parser
1 parentb0b3dec commit5e4cc71

File tree

1 file changed

+50
-46
lines changed

1 file changed

+50
-46
lines changed

‎.github/workflows/documentation-check.yaml‎

Lines changed: 50 additions & 46 deletions
Original file line numberDiff line numberDiff line change
@@ -91,12 +91,14 @@ jobs:
9191
GITHUB_REPOSITORY:${{ github.repository }}
9292
RUN_ID:${{ github.run_id }}
9393
run:|
94-
COMMENT_BODY="🤖 **Documentation Check Started**
94+
COMMENT_BODY=$(cat <<EOF
95+
🤖 **Documentation Check Started**
9596
96-
Analyzing PR changes to determine if documentation updates are needed...
97+
Analyzing PR changes to determine if documentation updates are needed...
9798
98-
[View workflow run](https://github.com/${GITHUB_REPOSITORY}/actions/runs/${RUN_ID})
99-
"
99+
[View workflow run](https://github.com/${GITHUB_REPOSITORY}/actions/runs/${RUN_ID})
100+
EOF
101+
)
100102
COMMENT_ID=$(gh pr comment "${PR_NUMBER}" --body "${COMMENT_BODY}" --repo "${GITHUB_REPOSITORY}" | grep -oP 'https://github.com/.*/pull/.*#issuecomment-\K\d+')
101103
echo "comment_id=${COMMENT_ID}" >> "${GITHUB_OUTPUT}"
102104
@@ -163,58 +165,58 @@ Analyzing PR changes to determine if documentation updates are needed...
163165
164166
# Build comprehensive prompt
165167
PROMPT=$(cat <<'EOF'
166-
Analyze PR ${pr_url} for documentation updates.
168+
Analyze PR ${pr_url} for documentation updates.
167169
168-
## Task Description
169-
You are tasked with analyzing code changes in a pull request and determining what documentation updates are needed. Please:
170+
## Task Description
171+
You are tasked with analyzing code changes in a pull request and determining what documentation updates are needed. Please:
170172
171-
1. Review the PR description and code changes to understand what was changed
172-
2. Examine the existing documentation in the docs/ directory
173-
3. Identify any of the following needs:
174-
-Updates required to existing documentation
175-
-Documentation that needs to be deprecated
176-
-New documentation that should be added
177-
4. Provide a clear, actionable list of documentation changes needed
173+
1. Review the PR description and code changes to understand what was changed
174+
2. Examine the existing documentation in the docs/ directory
175+
3. Identify any of the following needs:
176+
- Updates required to existing documentation
177+
- Documentation that needs to be deprecated
178+
- New documentation that should be added
179+
4. Provide a clear, actionable list of documentation changes needed
178180
179-
## PR Details
180-
**Title**: ${pr_title}
181+
## PR Details
182+
**Title**: ${pr_title}
181183
182-
**Description**:
183-
${pr_body}
184+
**Description**:
185+
${pr_body}
184186
185-
**Files Changed**:
186-
${files_changed}
187+
**Files Changed**:
188+
${files_changed}
187189
188-
**Code Diff**:
189-
```diff
190-
${pr_diff}
191-
```
190+
**Code Diff**:
191+
```diff
192+
${pr_diff}
193+
```
192194
193-
## Output Format
194-
Please provide your analysis in the following format:
195+
## Output Format
196+
Please provide your analysis in the following format:
195197
196-
### Documentation Updates Required
198+
### Documentation Updates Required
197199
198-
#### Updates to Existing Documentation
199-
-[List any existing docs that need updates with specific changes needed]
200+
#### Updates to Existing Documentation
201+
- [List any existing docs that need updates with specific changes needed]
200202
201-
#### Documentation to Deprecate
202-
-[List any docs that should be marked as deprecated or removed]
203+
#### Documentation to Deprecate
204+
- [List any docs that should be marked as deprecated or removed]
203205
204-
#### New Documentation Needed
205-
-[List any new documentation that should be created]
206+
#### New Documentation Needed
207+
- [List any new documentation that should be created]
206208
207-
#### No Changes Needed
208-
-[If no documentation changes are required, explain why]
209+
#### No Changes Needed
210+
- [If no documentation changes are required, explain why]
209211
210-
Be specific and provide file paths and section references where applicable.
211-
EOF
212+
Be specific and provide file paths and section references where applicable.
213+
EOF
212214
)
213215
# Expand variables in the prompt
214216
PROMPT=$(eval "cat <<EOF
215-
${PROMPT}
216-
EOF
217-
")
217+
${PROMPT}
218+
EOF
219+
")
218220
export PROMPT
219221
220222
export TASK_NAME="doccheck-pr-${PR_NUMBER}-${RUN_ID}"
@@ -253,14 +255,16 @@ EOF
253255
run:|
254256
TASK_OUTPUT=$(cat /tmp/task_output.txt)
255257
256-
COMMENT_BODY="🤖 **Documentation Check Complete**
258+
COMMENT_BODY=$(cat <<EOF
259+
🤖 **Documentation Check Complete**
257260
258-
${TASK_OUTPUT}
261+
${TASK_OUTPUT}
259262
260-
---
261-
Task:https://dev.coder.com/tasks/${TASK_NAME}
262-
[View workflow run](https://github.com/${GITHUB_REPOSITORY}/actions/runs/${RUN_ID})
263-
"
263+
---
264+
Task: https://dev.coder.com/tasks/${TASK_NAME}
265+
[View workflow run](https://github.com/${GITHUB_REPOSITORY}/actions/runs/${RUN_ID})
266+
EOF
267+
)
264268
265269
# Update the existing comment
266270
gh api \

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp