Skip to content

Merge branch 'master' of github.com:thirdeye-dev/thirdeye #304

Merge branch 'master' of github.com:thirdeye-dev/thirdeye

Merge branch 'master' of github.com:thirdeye-dev/thirdeye #304

Workflow file for this run

name: Auto-Format Python Code
on:
push:
branches:
- dev
- master
paths:
- '**.py'
jobs:
format:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Set up Python environment
uses: actions/setup-python@v2
with:
python-version: '3.9'
- name: Install dependencies
run: |
pip install black isort flake8 autoflake
- name: Remove unused imports with autoflake
run: autoflake --in-place --remove-all-unused-imports --remove-unused-variables --recursive . --exclude apps.py
- name: Format code with isort
run: isort .
- name: Format code with Black
run: black .
- name: Commit the generated schema
uses: stefanzweifel/git-auto-commit-action@v4
with:
commit_message: 🤖 Auto-formated Python code
# this gives the commit author the github bot pfp and username
commit_author: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
commit_user_email: 41898282+github-actions[bot]@users.noreply.github.com
file_pattern: "*.py"