From 65c50ca8b77362e8e1937e8e79d0fd46e50e1e11 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Markus=20M=C3=A4kel=C3=A4?= Date: Tue, 11 Sep 2018 07:35:08 +0300 Subject: [PATCH] Fix uncrustify script Add explicit path to the root source directory and allow invocation from other directories. Also included qc_sqlite sources but excluded the SQLite sources. Explicitly define the configuration in the MaxScale sources as the one that will be used. Changed from N invocations of uncrustify to one invocation with all files as the program arguments. This should give a slight speedup when formatting all sources. --- script/maxscale-uncrustify.sh | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/script/maxscale-uncrustify.sh b/script/maxscale-uncrustify.sh index 2bd267583..d5a48d41a 100755 --- a/script/maxscale-uncrustify.sh +++ b/script/maxscale-uncrustify.sh @@ -1,7 +1,6 @@ #!/bin/bash -for file in $(eval "list-src -x 'qc_sqlite pcre2 build'") -do - uncrustify --no-backup --replace --mtime $file -done +currdir=$(dirname $(realpath $0)) + +$currdir/list-src -x 'sqlite-src-3110100 pcre2' $currdir/..|xargs uncrustify -c $currdir/../uncrustify.cfg --no-backup --mtime