Commit 8dbf28ac authored by Jim Harris's avatar Jim Harris
Browse files

check_format.sh: fix up prints for shellcheck



Signed-off-by: default avatarJim Harris <james.r.harris@intel.com>
Change-Id: I55f04e2b4ad481ebc7a7f565ed7a7a10c4156f93
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/10549


Tested-by: default avatarSPDK CI Jenkins <sys_sgci@intel.com>
Community-CI: Broadcom CI <spdk-ci.pdl@broadcom.com>
Reviewed-by: default avatarChangpeng Liu <changpeng.liu@intel.com>
Reviewed-by: default avatarAleksey Marchuk <alexeymar@mellanox.com>
Reviewed-by: default avatarBen Walker <benjamin.walker@intel.com>
Reviewed-by: default avatarMonica Kenguva <monica.kenguva@intel.com>
Reviewed-by: default avatarPaul Luse <paul.e.luse@intel.com>
parent 7b284f62
Loading
Loading
Loading
Loading
+3 −3
Original line number Diff line number Diff line
@@ -481,7 +481,7 @@ function check_bash_static_analysis() {
	local rc=0

	if hash shellcheck 2> /dev/null; then
		echo -n "Checking Bash style..."
		echo -n "Checking Bash static analysis with shellcheck..."

		shellcheck_v=$(shellcheck --version | grep -P "version: [0-9\.]+" | cut -d " " -f2)

@@ -534,7 +534,7 @@ SC2119,SC2120,SC2128,SC2148,SC2153,SC2154,SC2164,SC2174,SC2178,SC2001,SC2206,SC2

		get_bash_files | xargs -P$(nproc) -n1 shellcheck $SHCH_ARGS &> shellcheck.log
		if [[ -s shellcheck.log ]]; then
			echo " Bash formatting errors detected!"
			echo " Bash shellcheck errors detected!"

			cat shellcheck.log
			if $SHCK_APPLY; then
@@ -548,7 +548,7 @@ SC2119,SC2120,SC2128,SC2148,SC2153,SC2154,SC2164,SC2174,SC2178,SC2001,SC2206,SC2
		fi
		rm -f shellcheck.log
	else
		echo "You do not have shellcheck installed so your Bash style is not being checked!"
		echo "You do not have shellcheck installed so your Bash static analysis is not being performed!"
	fi

	return $rc