From 66cd25d3ef771681252aa159ded48b00e5cf32e0 Mon Sep 17 00:00:00 2001 From: Daniel Agar Date: Sat, 22 Aug 2015 17:39:12 -0400 Subject: [PATCH] require Artistic Style Version 2.05.1 --- Tools/fix_code_style.sh | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/Tools/fix_code_style.sh b/Tools/fix_code_style.sh index 96c6d60f02..d8b424ae56 100755 --- a/Tools/fix_code_style.sh +++ b/Tools/fix_code_style.sh @@ -1,4 +1,14 @@ #!/bin/bash + +ASTYLE_VER=`astyle --version` +ASTYLE_VER_REQUIRED="Artistic Style Version 2.05.1" + +if [ "$ASTYLE_VER" != "$ASTYLE_VER_REQUIRED" ]; then + echo "Error: you're using ${ASTYLE_VER}, but PX4 requires ${ASTYLE_VER_REQUIRED}" + echo "You can get the correct version here: https://github.com/PX4/astyle/releases/tag/2.05.1" + exit 1 +fi + DIR=$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd ) astyle \ --options=$DIR/astylerc \