On Fri, Mar 15, 2019 at 02:27:55PM +0100, Andrea Bolognani wrote:
On Wed, 2019-03-06 at 09:34 +0000, Daniel P. Berrangé wrote:
> +++ b/.travis.yml
> @@ -11,26 +11,30 @@ matrix:
> - docker
> env:
> - IMAGE="ubuntu-18"
> - - DISTCHECK_CONFIGURE_FLAGS="--with-init-script=systemd"
> - - DOCKER_CMD="$LINUX_CMD"
> + - MAKE_ARGS="syntax-check distcheck
DISTCHECK_CONFIGURE_FLAGS=--with-init-script-systemd"
> + script:
> + - make -f tests/Makefile.ci.inc cibuild-$IMAGE
MAKE_ARGS="$MAKE_ARGS"
Having a separate 'script' for each job in the matrix defeats the
purpose of setting values in the environment.
This could be written just using the script: entry without any
env vars, but the env vars have the useful property that they
are displayed in the build result page. So you can see the
difference in each matrix entry at a glance.
I would drop MINGW_CMD, change the existing LINUX_CMD to
env:
global:
- LINUX_CMD='
if test "$MINGW"; then
make -f tests/Makefile.ci.inc "cibuild-$IMAGE"
MAKE_ARGS="$MAKE_ARGS" CONFIGURE="$MINGW-configure";
else
make -f tests/Makefile.ci.inc "cibuild-$IMAGE"
MAKE_ARGS="$MAKE_ARGS";
fi
'
and the existing default script to
script:
- /bin/sh -xc "$LINUX_CMD"
I really don't like having so many levels of indirection in the
commands. It gets painful to understand, especially when you
consider the shell quoting & escaping needs.
I'd rather have duplication of the "script" entry that is easy
to understand.
Regards,
Daniel
--
|:
https://berrange.com -o-
https://www.flickr.com/photos/dberrange :|
|:
https://libvirt.org -o-
https://fstop138.berrange.com :|
|:
https://entangle-photo.org -o-
https://www.instagram.com/dberrange :|