Bump zipp from 0.6.0 to 3.19.1 in /rock-paper-scissors-lizard-spock (… #27
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: Black | |
on: [push] | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
env: | |
TASK_TRIGGER: .push | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Set up Python 3.10 | |
uses: actions/setup-python@v3 | |
with: | |
python-version: '3.10' | |
- name: Install dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip install black==22.6.0 | |
- name: Run black | |
run: | | |
black --version | |
if [ -f ${TASK_TRIGGER} ]; then | |
echo "The file ${TASK_TRIGGER} exists, run black, write changes" | |
black . | |
else | |
echo "The file ${TASK_TRIGGER} doesn't exist, run black with the --check option, do not write changes" | |
black --check . | |
fi | |
- name: Commit and push if changed | |
run: |- | |
git diff | |
git config --global user.email "[email protected]" | |
git config --global user.name "run-black-bot" | |
git add -A | |
git commit -m "code style: black" || exit 0 | |
git push |