diff options
| -rwxr-xr-x | prepare-release | 35 |
1 files changed, 6 insertions, 29 deletions
diff --git a/prepare-release b/prepare-release index 5eef65276..7e417912c 100755 --- a/prepare-release +++ b/prepare-release @@ -25,29 +25,6 @@ librarysymbolsfromfile() { done | sort -u } -test_deb_control() { - echo "Package: apt-test-depends" - echo "Version: 1.0" - echo "Architecture: all" - printf "Depends:" - ( - for i in Build-Depends Build-Depends-Indep Build-Depends-Arch; do - grep-dctrl -ns $i -S apt ./debian/control && echo , - done - grep-dctrl -ns Depends -F Tests run-tests ./debian/tests/control - ) | tr '\n' ' '\ - | sed -r -e 's#<[^,<>()@]*>##g' \ - -e 's#@[^,<>()@]*@##g' \ - -e 's#\[linux-any\]*##g' \ - -e 's#\[[^][]*\]*##g' \ - -e 's#dpkg-dev \([^)]*\)#dpkg-dev#g' \ - -e 's#debhelper \([^)]*\)#debhelper#g' \ - -e 's#g\+\+ \([^)]*\)#g++#g' \ - -e 's#@##g' \ - -e 's#,(\s+,)+#, #g' \ - -e 's#\s+# #g' -} - if [ "$1" = 'pre-export' ]; then libraryversioncheck() { local LIBRARY="$1" @@ -185,11 +162,11 @@ elif [ "$1" = 'buildlog' ]; then shift done elif [ "$1" = 'travis-ci' ]; then - apt-get install -qy --no-install-recommends dctrl-tools equivs gdebi-core moreutils - - test_deb_control > test-control - equivs-build test-control - gdebi -n apt-test-depends_1.0_all.deb + apt-get build-dep -qy . + apt-get install -qy --no-install-recommends dctrl-tools + for t in $(grep '^Tests: ' debian/tests/control | cut -d':' -f 2- | tr ',' '\n'); do + apt-get satisfy -qy --no-install-recommends "base-files,$(grep-dctrl -ns Depends -F Tests $t ./debian/tests/control | sed -e 's#@[^,<>()@]*@\s*,\s*##g' -e 's#@\s*,\s*##g')" + done elif [ "$1" = 'coverage' ]; then DIR="${2:-./coverage}" git clean -dfX # remove ignored build artifacts for a clean start @@ -387,7 +364,7 @@ Both will format the diff properly. \t$0 coverage [output-dir] »travis-ci« is a shortcut to install all build- as well as test-dependencies -used by .travis.yml. +used in .gitlab-ci.yml and other CI infrastructure. »coverage« does a clean build with the right flags for coverage reporting, runs all tests and generates a html report in the end. |
