1
0
mirror of https://github.com/OpenRCT2/OpenRCT2 synced 2025-12-13 02:52:35 +01:00
Files
OpenRCT2/scripts/check-code-formatting
Margen67 3188865313 Script improvements (#14452)
shebang:
 Move parameters from set.
 Add newline after for consistency.
curl:
 Add -f;
  Prevents output on error.
 Use -O where applicable;
  -o with the same filename as the URL is pointless.
 Add -S after -s:
  Makes curl still error despite being silent.
build-symbols:
 Add zip fallback.
get-discord-rpc:
 Move git clone parameters before repository for readability.
 Use --depth 1 to speed up cloning.
install-nsis:
 Use ProgramData environment variable.
build-appimage-docker.sh:
 Add -e to docker run.
 Run script directly.
build-appimage.sh:
 Make if more consistent.
Remove unused Travis scripts.
setenv:
 unset instead of blanking variables.
vstool.cmd:
 Use ProgramFiles(x86) environment variable.
2021-04-12 19:01:15 -03:00

18 lines
402 B
Bash
Executable File

#!/bin/sh -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_bin -f `dirname $0`/..)"
cd $basedir
scripts/run-clang-format.py -r src test --exclude src/thirdparty