ci: add python file checks to ci
Some checks failed
continuous-integration/drone/push Build is failing
Some checks failed
continuous-integration/drone/push Build is failing
This commit is contained in:
parent
bcb33e95ab
commit
972e67a507
@ -13,6 +13,28 @@ local PipelineLinting = {
|
|||||||
'ansible-later',
|
'ansible-later',
|
||||||
],
|
],
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
name: 'python-format',
|
||||||
|
image: 'python:3.9',
|
||||||
|
environment: {
|
||||||
|
PY_COLORS: 1,
|
||||||
|
},
|
||||||
|
commands: [
|
||||||
|
'pip install -qq yapf',
|
||||||
|
'yapf -dr ./',
|
||||||
|
],
|
||||||
|
},
|
||||||
|
{
|
||||||
|
name: 'python-flake8',
|
||||||
|
image: 'python:3.9',
|
||||||
|
environment: {
|
||||||
|
PY_COLORS: 1,
|
||||||
|
},
|
||||||
|
commands: [
|
||||||
|
'pip install -qq flake8',
|
||||||
|
'flake8',
|
||||||
|
],
|
||||||
|
},
|
||||||
],
|
],
|
||||||
trigger: {
|
trigger: {
|
||||||
ref: ['refs/heads/master', 'refs/tags/**', 'refs/pull/**'],
|
ref: ['refs/heads/master', 'refs/tags/**', 'refs/pull/**'],
|
||||||
|
18
.drone.yml
18
.drone.yml
@ -12,6 +12,22 @@ steps:
|
|||||||
commands:
|
commands:
|
||||||
- ansible-later
|
- ansible-later
|
||||||
|
|
||||||
|
- name: python-format
|
||||||
|
image: python:3.9
|
||||||
|
commands:
|
||||||
|
- pip install -qq yapf
|
||||||
|
- yapf -dr ./
|
||||||
|
environment:
|
||||||
|
PY_COLORS: 1
|
||||||
|
|
||||||
|
- name: python-flake8
|
||||||
|
image: python:3.9
|
||||||
|
commands:
|
||||||
|
- pip install -qq flake8
|
||||||
|
- flake8
|
||||||
|
environment:
|
||||||
|
PY_COLORS: 1
|
||||||
|
|
||||||
trigger:
|
trigger:
|
||||||
ref:
|
ref:
|
||||||
- refs/heads/master
|
- refs/heads/master
|
||||||
@ -99,6 +115,6 @@ depends_on:
|
|||||||
|
|
||||||
---
|
---
|
||||||
kind: signature
|
kind: signature
|
||||||
hmac: f2bf2d0a3d0fe97259cb32556d4b778f5b6a40a94df3e03b762c9ce19111df70
|
hmac: 63b88cb2117656d532c57cc38b652a39d92923f145aef0a70872916791f41f0d
|
||||||
|
|
||||||
...
|
...
|
||||||
|
Loading…
Reference in New Issue
Block a user