From 7de6bd74d7bef55acddb1f3c34d29d08acfa40f9 Mon Sep 17 00:00:00 2001 From: Robert Kaussow Date: Tue, 8 Jun 2021 09:05:27 +0200 Subject: [PATCH] fix ci yapf command if no python files found --- .../.drone.jsonnet | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/{{cookiecutter.author}}.{{cookiecutter.role_name}}/.drone.jsonnet b/{{cookiecutter.author}}.{{cookiecutter.role_name}}/.drone.jsonnet index 50a5596..6a8c8fa 100644 --- a/{{cookiecutter.author}}.{{cookiecutter.role_name}}/.drone.jsonnet +++ b/{{cookiecutter.author}}.{{cookiecutter.role_name}}/.drone.jsonnet @@ -21,7 +21,7 @@ local PipelineLinting = { }, commands: [ 'pip install -qq yapf', - 'yapf -dr ./', + '[ ! -z "$(find . -type f -name *.py)" ] && yapf -rd ./', ], }, {