mirror of
https://github.com/ansible-collections/kubernetes.core.git
synced 2026-07-29 02:44:41 +00:00
automated changes for black formatting (#611)
This commit is contained in:
17
.github/workflows/black.yml
vendored
Normal file
17
.github/workflows/black.yml
vendored
Normal file
@@ -0,0 +1,17 @@
|
|||||||
|
---
|
||||||
|
name: black
|
||||||
|
|
||||||
|
concurrency:
|
||||||
|
group: '${{ github.workflow }} @ ${{ github.sha }}'
|
||||||
|
cancel-in-progress: true
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- main
|
||||||
|
- 'stable-*'
|
||||||
|
pull_request_target:
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
format:
|
||||||
|
uses: abikouo/github_actions/.github/workflows/black.yml@automate_changes_a
|
||||||
12
tox.ini
12
tox.ini
@@ -19,27 +19,27 @@ commands=
|
|||||||
deps = git+https://github.com/ansible-network/collection_prep
|
deps = git+https://github.com/ansible-network/collection_prep
|
||||||
commands = collection_prep_add_docs -p .
|
commands = collection_prep_add_docs -p .
|
||||||
|
|
||||||
[testenv:black]
|
[testenv:black_check]
|
||||||
deps =
|
deps =
|
||||||
black >= 22.0, < 23.0
|
black >= 22.0, < 23.0
|
||||||
|
|
||||||
commands =
|
commands =
|
||||||
black -v --check --diff {toxinidir}/plugins {toxinidir}/tests
|
black -v --check --diff {toxinidir}/plugins {toxinidir}/tests
|
||||||
|
|
||||||
[testenv:black_format]
|
[testenv:black]
|
||||||
deps =
|
deps =
|
||||||
{[testenv:black]deps}
|
{[testenv:black_check]deps}
|
||||||
|
|
||||||
commands =
|
commands =
|
||||||
black -v {posargs}
|
black -v {posargs:{toxinidir}/plugins {toxinidir}/tests}
|
||||||
|
|
||||||
[testenv:linters]
|
[testenv:linters]
|
||||||
deps =
|
deps =
|
||||||
yamllint
|
yamllint
|
||||||
flake8
|
flake8
|
||||||
{[testenv:black]deps}
|
{[testenv:black_check]deps}
|
||||||
|
|
||||||
commands =
|
commands =
|
||||||
{[testenv:black]commands}
|
{[testenv:black_check]commands}
|
||||||
yamllint -s {toxinidir}
|
yamllint -s {toxinidir}
|
||||||
flake8 {toxinidir}
|
flake8 {toxinidir}
|
||||||
|
|||||||
Reference in New Issue
Block a user