Fix shellcheck SC2126: Consider using grep -c instead of grep|wc. We can use -q as suggested by Daniel because we don't care about the exact count. Signed-off-by: Jani Nikula <jani.nikula@xxxxxxxxx> --- Makefile | 1 - dim | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/Makefile b/Makefile index 139fd82ba441..1f628e9489f9 100644 --- a/Makefile +++ b/Makefile @@ -26,7 +26,6 @@ SC_EXCLUDE := \ -e SC2086 \ -e SC2119 \ -e SC2120 \ - -e SC2126 \ -e SC2143 shellcheck: diff --git a/dim b/dim index d961bb493616..33b393d3f27a 100755 --- a/dim +++ b/dim @@ -502,7 +502,7 @@ function dim_rebuild_tip rerere=$DIM_PREFIX/drm-rerere cd $rerere - if [[ $(git status --porcelain | grep -v "^[ ?][ ?]" | wc -l) -gt 0 ]]; then + if git status --porcelain | grep -q -v "^[ ?][ ?]"; then warn_or_fail "integration configuration file $integration_config not commited" fi -- 2.1.4 _______________________________________________ Intel-gfx mailing list Intel-gfx@xxxxxxxxxxxxxxxxxxxxx https://lists.freedesktop.org/mailman/listinfo/intel-gfx