summaryrefslogtreecommitdiffstats
path: root/coverity-scan.sh
diff options
context:
space:
mode:
authorPaweł Krupa <pawel@krupa.net.pl>2018-09-26 09:57:13 +0200
committerGitHub <noreply@github.com>2018-09-26 09:57:13 +0200
commit545eb2fd29abcf2be55f5ffc341a53d246558f8d (patch)
tree5e29eb1c8674ad896fb3e0e919728b2ffae4cbab /coverity-scan.sh
parent3e929ad4ee249d54efd52c48889f611958b8c294 (diff)
update variable after install (#4292)
* update variable after install * normalize indent
Diffstat (limited to 'coverity-scan.sh')
-rwxr-xr-xcoverity-scan.sh13
1 files changed, 7 insertions, 6 deletions
diff --git a/coverity-scan.sh b/coverity-scan.sh
index 88bc3ebd58..6b24aa1c45 100755
--- a/coverity-scan.sh
+++ b/coverity-scan.sh
@@ -19,14 +19,15 @@ covbuild="$(which cov-build 2>/dev/null || command -v cov-build 2>/dev/null)"
([ -z "${covbuild}" ] && [ -f .coverity-build ]) && covbuild="$(<.coverity-build)"
if [ -z "${covbuild}" ]; then
echo "Cannot find 'cov-build' binary in \$PATH."
- if [ $INSTALL_COVERITY != "" ]; then
+ if [ "${INSTALL_COVERITY}" != "" ]; then
echo "Installing coverity..."
mkdir /tmp/coverity
- curl -SL --data "token=${token}&project=netdata%2Fnetdata" https://scan.coverity.com/download/linux64 > /tmp/coverity_tool.tar.gz
- tar -x -C /tmp/coverity/ -f /tmp/coverity_tool.tar.gz
- sudo mv /tmp/coverity/cov-analysis-linux64-2017.07 /opt/coverity
- export PATH=${PATH}:/opt/coverity/bin/
- else
+ curl -SL --data "token=${token}&project=netdata%2Fnetdata" https://scan.coverity.com/download/linux64 > /tmp/coverity_tool.tar.gz
+ tar -x -C /tmp/coverity/ -f /tmp/coverity_tool.tar.gz
+ sudo mv /tmp/coverity/cov-analysis-linux64-2017.07 /opt/coverity
+ export PATH=${PATH}:/opt/coverity/bin/
+ covbuild="$(which cov-build 2>/dev/null || command -v cov-build 2>/dev/null)"
+ else
echo "Save command the full filename of cov-build in .coverity-build"
exit 1
fi