[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH 2/3] scripts/run-coverity-scan: Script to run Co
From: |
Eric Blake |
Subject: |
Re: [Qemu-devel] [PATCH 2/3] scripts/run-coverity-scan: Script to run Coverity Scan build |
Date: |
Thu, 29 Jun 2017 11:12:47 -0500 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.2.0 |
On 06/13/2017 10:54 AM, Peter Maydell wrote:
> Add a new script to automate the process of running the Coverity
> Scan build tools and uploading the resulting tarball to the
> website. This is primarily intended to be driven from Travis,
> but it can be run locally (if you are a maintainer of the
> QEMU project on the Coverity Scan website and have the secret
> upload token).
>
> Signed-off-by: Peter Maydell <address@hidden>
> ---
> scripts/run-coverity-scan | 170
> ++++++++++++++++++++++++++++++++++++++++++++++
> 1 file changed, 170 insertions(+)
> create mode 100755 scripts/run-coverity-scan
>
> diff --git a/scripts/run-coverity-scan b/scripts/run-coverity-scan
> new file mode 100755
> index 0000000..e6d5fc5
> --- /dev/null
> +++ b/scripts/run-coverity-scan
> @@ -0,0 +1,170 @@
> +#!/bin/sh -e
I'm not a fan of 'set -e'; it seldom does what you think it should do,
especially when shell functions are involved. It's better to be
explicit about error handling than it is to rely on a crutch that has
well-defined but non-intuitive behavior.
> +mkdir -p "$COVERITY_TOOL_BASE"
> +cd "$COVERITY_TOOL_BASE"
> +
Of course, calls like these are where you have to either be explicit or
rely on the 'set -e' crutch.
Thankfully, I didn't see any bashisms, so you appeared to have stuck to
portable /bin/sh code.
--
Eric Blake, Principal Software Engineer
Red Hat, Inc. +1-919-301-3266
Virtualization: qemu.org | libvirt.org
signature.asc
Description: OpenPGP digital signature
- Re: [Qemu-devel] [PATCH 1/3] travis: install more library dependencies, (continued)