From 43d55c5afb1a9f731d806f7893923ac999b9ef6c Mon Sep 17 00:00:00 2001 From: Raghavendra Talur Date: Mon, 10 Jul 2017 20:43:39 +0530 Subject: rfc.sh: make alignment check compulsory Earlier, it was not reported if a function call had arguments on next line and the args were not aligned to opening bracket. With this change, it is a check that is displayed in output. I have not analyzed what all --strict brings in. If it is found to be more restrictive than required, we may choose to promote this *one* CHK to WARN and stop using --strict. Sample: CHECK: Alignment should match open parenthesis + ret = gf_asprintf (&footer, + " [%s]", strerror(errnum)); total: 0 warnings, 1 checks, 8 lines checked Change-Id: I48834087efcae872b69746ba962b0bb1c130b5cd BUG: 1469179 Signed-off-by: Raghavendra Talur Reviewed-on: https://review.gluster.org/17737 CentOS-regression: Gluster Build System Smoke: Gluster Build System Reviewed-by: Prashanth Pai Reviewed-by: ankitraj Reviewed-by: Jeff Darcy Reviewed-by: Sonal Arora Reviewed-by: Niels de Vos --- rfc.sh | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'rfc.sh') diff --git a/rfc.sh b/rfc.sh index 0123a220776..b58c65de33b 100755 --- a/rfc.sh +++ b/rfc.sh @@ -180,17 +180,17 @@ check_patches_for_coding_style() # Kludge: "1>&2 && echo $? || echo $?" is to get around # "-e" from script invocation RES=$(git format-patch --stdout origin/${branch}..${head} \ - | ${check_patch_script} --terse - 1>&2 && echo $? || echo $?) + | ${check_patch_script} --strict --terse - 1>&2 && echo $? || echo $?) if [ "$RES" -eq 1 ] ; then echo "Errors caught, get details by:" echo " git format-patch --stdout origin/${branch}..${head} \\" - echo " | ${check_patch_script} --gerrit-url ${GERRIT_URL} -" + echo " | ${check_patch_script} --strict --gerrit-url ${GERRIT_URL} -" echo "and correct errors" exit 1 elif [ "$RES" -eq 2 ] ; then - echo "Warnings caught, get details by:" + echo "Warnings or checks caught, get details by:" echo " git format-patch --stdout origin/${branch}..${head} \\" - echo " | ${check_patch_script} --gerrit-url ${GERRIT_URL} -" + echo " | ${check_patch_script} --strict --gerrit-url ${GERRIT_URL} -" echo -n "Do you want to continue anyway [no/yes]: " read yesno if [ "${yesno}" != "yes" ] ; then -- cgit