checks #22
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Validate PR Comment | |
on: | |
issue_comment: | |
jobs: | |
validate: | |
if: ${{ github.event.issue.pull_request }} | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
with: | |
ref: ${{ github.event.issue.pull_request.head.sha }} | |
- run: | | |
echo ${{ github.event.issue.pull_request.body }} | |
echo ${{ github.event.issue.pull_request.head.sha }} | |
- name: 🐍 Setting Python | |
uses: actions/setup-python@v4 | |
with: | |
python-version: '3.10' | |
cache: 'pip' | |
- run: | | |
python -m pip install --upgrade pip | |
pip install -r .github/requirements.txt | |
python .github/validate_comment.py --body ${{ github.event.comment.body }} | |
if [ $? -ne 0 ]; then | |
echo "Validation failed!" | |
exit 1 | |
fi |