diff --git a/.github/workflows/clang-format.yml b/.github/workflows/clang-format.yml index e7caba461..5407ade79 100644 --- a/.github/workflows/clang-format.yml +++ b/.github/workflows/clang-format.yml @@ -13,7 +13,7 @@ jobs: - name: Install clang format run: | - sudo apt-get install -y clang-format-10 + sudo apt-get install -y clang-format-12 - name: Check the Formatting run: | diff --git a/formatcode.sh b/formatcode.sh index f776cf229..7144c6040 100755 --- a/formatcode.sh +++ b/formatcode.sh @@ -19,7 +19,9 @@ if [[ $OS = "Linux" || $OS = "Darwin" ]] ; then fi # Discover clang-format -if type clang-format-10 2> /dev/null ; then +if type clang-format-12 2> /dev/null ; then + CLANG_FORMAT=clang-format-12 +elif type clang-format-10 2> /dev/null ; then CLANG_FORMAT=clang-format-10 elif type clang-format-8 2> /dev/null ; then CLANG_FORMAT=clang-format-8