build: merge branch 'ss/python-improvements'

https://gitlab.freedesktop.org/NetworkManager/NetworkManager/-/merge_requests/540
This commit is contained in:
Thomas Haller 2020-06-19 12:59:11 +02:00
commit d64eb7201e
No known key found for this signature in database
GPG key ID: 29C2366E4DFC5728
3 changed files with 13 additions and 2 deletions

View file

@ -74,11 +74,12 @@ stages:
- date '+%Y%m%d-%H%M%S'; test "$NM_BUILD_TARBALL" != 1 || mv /tmp/NetworkManager-1*.tar.xz /tmp/NetworkManager-1*.src.rpm ./
checkpatch:
image: fedora:29
image: fedora:32
stage: test
script:
- date '+%Y%m%d-%H%M%S'; dnf install -y git
- date '+%Y%m%d-%H%M%S'; dnf install -y git black
- date '+%Y%m%d-%H%M%S'; NM_CHECKPATCH_FETCH_UPSTREAM=1 contrib/scripts/checkpatch-feature-branch.sh 2>&1 | tee checkpatch-out.txt
- date '+%Y%m%d-%H%M%S'; black --check .
allow_failure: true
artifacts:
when: on_failure

View file

@ -5236,6 +5236,12 @@ CLEANFILES += \
include Makefile.examples
if WITH_PYTHON_BLACK
check-python-black:
test "$$NMTST_SKIP_PYTHON_BLACK" != 1 && $(BLACK) --check $(top_srcdir)
check_local += check-python-black
endif
###############################################################################
check-local: $(check_local)

View file

@ -1272,6 +1272,10 @@ else
have_introspection=no
fi
# check for python black. And check if all files are formatted with python black
AC_PATH_PROG(BLACK, black)
AM_CONDITIONAL(WITH_PYTHON_BLACK, test "${BLACK}" != "")
# check for pregenerated manpages and documentation to be installed
use_pregen_docs=no
if test "$build_docs" != "yes" -a \