Skip to content

Commit 6324d04

Browse files
committed
Update GitHub Actions workflow to improve analysis output formatting
- Modified the analyze job to append results to the output file instead of overwriting it, preserving previous analysis data. - Added markdown formatting to the results file for better readability, including a header and code block encapsulation. - Included a timestamp and Python version information at the end of the results file for context.
1 parent 2a269aa commit 6324d04

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

.github/workflows/analyze.yml

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,9 +30,17 @@ jobs:
3030
run: |
3131
# 创建结果目录
3232
mkdir -p results
33+
34+
touch results/RESULT.md
35+
36+
echo "## 分析结果" > results/RESULT.md
37+
38+
echo "```" >> results/RESULT.md
3339
3440
# 运行分析器并将输出重定向到文件
35-
github-stats ${{ github.repository_owner }} --access-level full > results/RESULT.md
41+
github-stats ${{ github.repository_owner }} --access-level full >> results/RESULT.md
42+
43+
echo "```" >> results/RESULT.md
3644
3745
# 添加时间戳和 Python 版本信息
3846
echo -e "\n\n---\nLast updated: $(date -u)\nPython version: $(python --version)" >> results/RESULT.md

0 commit comments

Comments
 (0)