Skip to content

build(deps): bump jinja2 from 2.11.3 to 3.1.3 in /requirements #241

build(deps): bump jinja2 from 2.11.3 to 3.1.3 in /requirements

build(deps): bump jinja2 from 2.11.3 to 3.1.3 in /requirements #241

Workflow file for this run

name: format
# Run this workflow every time on push
on: push
jobs:
# Set the job key. The key is displayed as the job name
# when a job name is not provided
python-format:
# Name the Job
name: Run black python formatter
# Set the type of machine to run on
runs-on: ubuntu-latest
strategy:
matrix:
python-version: [3.8]
steps:
# Checks out a copy of your repository on the ubuntu-latest machine
- uses: actions/checkout@v2
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Format with black
run: |
$CONDA/bin/conda install -c conda-forge black==20.8b1 click==8.0.4
# stop the build if there are Python syntax errors or undefined names
$CONDA/bin/black minian
- name: Check for modified files
id: git-check
run: echo ::set-output name=modified::$(if git diff-index --quiet HEAD --; then echo "false"; else echo "true"; fi)
- name: Push changes
if: steps.git-check.outputs.modified == 'true'
run: |
git config --global user.name 'DeniseCaiLab'
git config --global user.email 'denisecailab@gmail.com'
git remote set-url origin https://x-access-token:${{ secrets.GITHUB_TOKEN }}@github.com/$GITHUB_REPOSITORY
git checkout `basename $GITHUB_REF`
git commit -am "Automated changes, black formatter"
git push origin HEAD:`basename $GITHUB_REF`