Leonardo Sandoval | 9dfdd1b | 2020-08-06 17:08:11 -0500 | [diff] [blame^] | 1 | #!/usr/bin/env bash |
Zelalem | 917b43e | 2020-08-04 11:39:55 -0500 | [diff] [blame] | 2 | # |
| 3 | # Copyright (c) 2019, Arm Limited. All rights reserved. |
| 4 | # |
| 5 | # SPDX-License-Identifier: BSD-3-Clause |
| 6 | # |
| 7 | |
| 8 | # This script runs the static checks in tf-static-checks |
| 9 | # jenkins job. |
| 10 | |
| 11 | if [ "$REPO_UNDER_TEST" = "trusted-firmware" ]; then |
| 12 | cd "$TF_CHECKOUT_LOC" |
| 13 | else |
| 14 | cd "$TFTF_CHECKOUT_LOC" |
| 15 | fi |
| 16 | |
| 17 | export IS_CONTINUOUS_INTEGRATION=1 |
| 18 | static_fail=0 |
| 19 | |
| 20 | if ! "$CI_ROOT/script/static-checks/static-checks.sh"; then |
| 21 | static_fail=1 |
| 22 | fi |
| 23 | |
| 24 | if [ -f "static-checks.log" ]; then |
| 25 | mv "static-checks.log" "$WORKSPACE" |
| 26 | fi |
| 27 | |
| 28 | exit "$static_fail" |