diff options
Diffstat (limited to 'Meta')
-rw-r--r-- | Meta/Azure/Setup.yml | 4 | ||||
-rwxr-xr-x | Meta/lint-clang-format.sh | 18 |
2 files changed, 11 insertions, 11 deletions
diff --git a/Meta/Azure/Setup.yml b/Meta/Azure/Setup.yml index 97fc47f662..c24b7eb5ca 100644 --- a/Meta/Azure/Setup.yml +++ b/Meta/Azure/Setup.yml @@ -8,9 +8,9 @@ steps: - ${{ if eq(parameters.os, 'Serenity') }}: - script: | wget -O - https://apt.llvm.org/llvm-snapshot.gpg.key | sudo apt-key add - - sudo add-apt-repository 'deb http://apt.llvm.org/jammy/ llvm-toolchain-jammy-14 main' + sudo add-apt-repository 'deb http://apt.llvm.org/jammy/ llvm-toolchain-jammy-15 main' sudo apt-get update - sudo apt-get install clang-format-14 ccache e2fsprogs gcc-12 g++-12 libstdc++-12-dev libmpfr-dev libmpc-dev ninja-build qemu-utils qemu-system-i386 unzip lld + sudo apt-get install clang-format-15 ccache e2fsprogs gcc-12 g++-12 libstdc++-12-dev libmpfr-dev libmpc-dev ninja-build qemu-utils qemu-system-i386 unzip lld displayName: 'Install Dependencies' - ${{ if eq(parameters.os, 'Linux') }}: diff --git a/Meta/lint-clang-format.sh b/Meta/lint-clang-format.sh index 6641476302..d8746c1984 100755 --- a/Meta/lint-clang-format.sh +++ b/Meta/lint-clang-format.sh @@ -28,21 +28,21 @@ fi if (( ${#files[@]} )); then TOOLCHAIN_DIR=Toolchain/Local/clang/bin CLANG_FORMAT=false - if command -v clang-format-14 >/dev/null 2>&1 ; then - CLANG_FORMAT=clang-format-14 - elif command -v brew >/dev/null 2>&1 && command -v "$(brew --prefix llvm@14)"/bin/clang-format >/dev/null 2>&1 ; then - CLANG_FORMAT="$(brew --prefix llvm@14)"/bin/clang-format - elif command -v $TOOLCHAIN_DIR/clang-format >/dev/null 2>&1 && $TOOLCHAIN_DIR/clang-format --version | grep -qF ' 14.' ; then + if command -v clang-format-15 >/dev/null 2>&1 ; then + CLANG_FORMAT=clang-format-15 + elif command -v brew >/dev/null 2>&1 && command -v "$(brew --prefix llvm@15)"/bin/clang-format >/dev/null 2>&1 ; then + CLANG_FORMAT="$(brew --prefix llvm@15)"/bin/clang-format + elif command -v $TOOLCHAIN_DIR/clang-format >/dev/null 2>&1 && $TOOLCHAIN_DIR/clang-format --version | grep -qF ' 15.' ; then CLANG_FORMAT=$TOOLCHAIN_DIR/clang-format elif command -v clang-format >/dev/null 2>&1 ; then CLANG_FORMAT=clang-format - if ! "${CLANG_FORMAT}" --version | awk '{ if (substr($NF, 1, index($NF, ".") - 1) < 14) exit 1; }'; then - echo "You are using '$("${CLANG_FORMAT}" --version)', which appears to not be clang-format 14 or later." + if ! "${CLANG_FORMAT}" --version | awk '{ if (substr($NF, 1, index($NF, ".") - 1) < 15) exit 1; }'; then + echo "You are using '$("${CLANG_FORMAT}" --version)', which appears to not be clang-format 15 or later." echo "It is very likely that the resulting changes are not what you wanted." fi else - echo "clang-format-14 is not available, but C or C++ files need linting! Either skip this script, or install clang-format-14." - echo "(If you install a package 'clang-format', please make sure it's version 14 or later.)" + echo "clang-format-15 is not available, but C or C++ files need linting! Either skip this script, or install clang-format-15." + echo "(If you install a package 'clang-format', please make sure it's version 15 or later.)" exit 1 fi |