Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion .github/workflows/mypy_primer.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ on:
- "crates/ruff_python_ast"
- "crates/ruff_python_parser"
- ".github/workflows/mypy_primer.yaml"
- ".github/workflows/mypy_primer_comment.yaml"

concurrency:
group: ${{ github.workflow }}-${{ github.ref_name }}-${{ github.event.pull_request.number || github.sha }}
Expand Down Expand Up @@ -67,7 +68,7 @@ jobs:
--new "$GITHUB_SHA" \
--project-selector '/(mypy_primer|black|pyp|git-revise|zipp|arrow)$' \
--output concise \
--debug | tee mypy_primer.diff
--debug | tee /dev/stdout | sed -e 's/\x1b\[[0-9;]*m//g' > mypy_primer.diff
) || [ $? -eq 1 ]
echo ${{ github.event.number }} > pr-number
Expand Down
10 changes: 7 additions & 3 deletions .github/workflows/mypy_primer_comment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -62,9 +62,13 @@ jobs:
echo '<!-- generated-comment mypy_primer -->' >> comment.txt

echo '## `mypy_primer` results' >> comment.txt
echo '```diff' >> comment.txt
cat pr/mypy_primer_diff/mypy_primer.diff >> comment.txt
echo '```' >> comment.txt
if [ -s "pr/mypy_primer_diff/mypy_primer.diff" ]; then
echo '```diff' >> comment.txt
cat pr/mypy_primer_diff/mypy_primer.diff >> comment.txt
echo '```' >> comment.txt
else
echo 'No ecosystem changes detected ✅' >> comment.txt
fi

echo 'comment<<EOF' >> "$GITHUB_OUTPUT"
cat comment.txt >> "$GITHUB_OUTPUT"
Expand Down
Loading