From 499b9aab0b0780a54d7ecbb15b37155d53d310b4 Mon Sep 17 00:00:00 2001 From: Maciej Szwed Date: Fri, 20 Jul 2018 13:11:52 +0200 Subject: [PATCH] scripts: check astyle version As we changed astyle version in our CI environment some users may get fails on format check. This patch adds check for astyle version and informs user that there may be some errors from CI if astyle version is too old. Signed-off-by: Maciej Szwed Change-Id: I1c9565c51828411bbc7066f34b55e54f2b17bd8b Reviewed-on: https://review.gerrithub.io/420010 Chandler-Test-Pool: SPDK Automated Test System Tested-by: SPDK CI Jenkins Reviewed-by: Ben Walker Reviewed-by: Shuhei Matsumoto --- scripts/check_format.sh | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/scripts/check_format.sh b/scripts/check_format.sh index 4d20e8064..991d3b7a0 100755 --- a/scripts/check_format.sh +++ b/scripts/check_format.sh @@ -10,6 +10,10 @@ rc=0 if hash astyle; then echo -n "Checking coding style..." + if [ "$(astyle -V)" \< "Artistic Style Version 3" ] + then + echo -n " Your astyle version is too old. This may cause failure on patch verification performed by CI. Please update astyle to at least 3.0.1 version..." + fi rm -f astyle.log touch astyle.log # Exclude rte_vhost code imported from DPDK - we want to keep the original code