diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml new file mode 100644 index 0000000000000000000000000000000000000000..375a48d3a05bf4f81ade915c27196f6f27cd71b5 --- /dev/null +++ b/.pre-commit-config.yaml @@ -0,0 +1,19 @@ +repos: + - repo: https://github.com/ambv/black + rev: 20.8b1 + hooks: + - id: black + - repo: https://github.com/pre-commit/pre-commit-hooks + rev: v2.3.0 + hooks: + - id: flake8 + - repo: https://github.com/pre-commit/pre-commit-hooks + rev: v2.3.0 + hooks: + - id: end-of-file-fixer + - id: trailing-whitespace + - repo: https://github.com/timothycrosley/isort + rev: 5.2.1 + hooks: + - id: isort + args: ["--profile", "black"] diff --git a/require-ess/tools/driver.makefile b/require-ess/tools/driver.makefile index 8cf15d9db2fbf837b2d4b0bbc973b018339db4fb..03abfec3817c3663668085cbef660bb25df72e26 100644 --- a/require-ess/tools/driver.makefile +++ b/require-ess/tools/driver.makefile @@ -547,7 +547,7 @@ export CFG ${PRJ}_GIT_DESC := $(shell git describe --tags 2> /dev/null || git rev-parse HEAD 2> /dev/null) export ${PRJ}_GIT_DESC # The formatting here is just to make sure this is properly parseable .yaml data -${PRJ}_GIT_STATUS := [ $(shell git status --porcelain | grep -v "\.Makefile" | sed 's/^/\\\"/' | sed 's/$$/\\\", /')] +${PRJ}_GIT_STATUS := [ $(shell git status --porcelain 2> /dev/null | grep -v "\.Makefile" | sed 's/^/\\\"/' | sed 's/$$/\\\", /')] export ${PRJ}_GIT_STATUS else # in O.*