mirror of
https://github.com/OpenRCT2/OpenRCT2
synced 2025-12-10 09:32:29 +01:00
Adjust code formatting checks script for macOS (#10930)
This commit is contained in:
committed by
GitHub
parent
4f6f3feeb2
commit
2277c8ee4a
@@ -1,8 +1,18 @@
|
||||
#!/bin/sh
|
||||
set -e
|
||||
|
||||
readlink_bin='readlink'
|
||||
|
||||
if [[ "$OSTYPE" == "darwin"* ]]; then
|
||||
if ! [ -x "$(command -v greadlink)" ]; then
|
||||
echo 'Please install greadlink with Homebrew: brew install coreutils'
|
||||
exit 1
|
||||
fi
|
||||
readlink_bin='greadlink'
|
||||
fi
|
||||
|
||||
# Ensure we are in root directory
|
||||
basedir="$(readlink -f `dirname $0`/..)"
|
||||
basedir="$($readlink_bin -f `dirname $0`/..)"
|
||||
cd $basedir
|
||||
|
||||
scripts/run-clang-format.py -r src test --exclude src/thirdparty
|
||||
|
||||
Reference in New Issue
Block a user