summaryrefslogtreecommitdiff
path: root/other
diff options
context:
space:
mode:
authoriphydf <iphydf@users.noreply.github.com>2018-02-21 14:15:57 +0000
committeriphydf <iphydf@users.noreply.github.com>2018-02-21 15:45:31 +0000
commit414b8f7425aeb22b02a1649830cf96e7ac1163b0 (patch)
tree579c5dc4d0aef88c61823649f2f5326a7638bd60 /other
parentee53d96447c3b8cc13a897a567c0cd3fb76b0970 (diff)
Fix OSX tests: find(1) doesn't work like on Linux.
Diffstat (limited to 'other')
-rwxr-xr-xother/astyle/format-source16
1 files changed, 9 insertions, 7 deletions
diff --git a/other/astyle/format-source b/other/astyle/format-source
index 5b61273a..5b560622 100755
--- a/other/astyle/format-source
+++ b/other/astyle/format-source
@@ -1,6 +1,6 @@
1#!/bin/sh 1#!/bin/sh
2 2
3set -e 3set -ex
4 4
5SOURCE_DIR="$1" 5SOURCE_DIR="$1"
6ASTYLE="$2" 6ASTYLE="$2"
@@ -47,12 +47,14 @@ if grep '<unresolved>' */*.h; then
47 exit 1 47 exit 1
48fi 48fi
49 49
50SOURCES=`find . \ 50FIND="find ."
51 "-(" -name "*.[ch]" -or -name "*.cpp" "-)" \ 51FIND="$FIND '(' -name '*.[ch]' -or -name '*.cpp' ')'"
52 -and -not -name "*.api.h" \ 52FIND="$FIND -and -not -name '*.api.h'"
53 -and -not -wholename "./super_donators/*" \ 53FIND="$FIND -and -not -wholename './super_donators/*'"
54 -and -not -wholename "./third_party/*" \ 54FIND="$FIND -and -not -wholename './third_party/*'"
55 -and -not -wholename "./toxencryptsave/crypto_pwhash*"` 55FIND="$FIND -and -not -wholename './toxencryptsave/crypto_pwhash*'"
56
57SOURCES=`eval "$FIND"`
56 58
57$ASTYLE -n --options=other/astyle/astylerc $SOURCES 59$ASTYLE -n --options=other/astyle/astylerc $SOURCES
58 60