add clang-format version to format-cxxcode
MODIFY
azure-pipelines/Format-CxxCode.ps1
azure-pipelines/Format-CxxCode.ps1
+#! /usr/bin/env pwsh
+
[CmdletBinding()]
$Root = Resolve-Path -LiteralPath "$PSScriptRoot/.."
@@ -25,6 +27,9 @@ if ([String]::IsNullOrEmpty($clangFormat) -or -not (Test-Path $clangFormat))
throw
}
+$clangFormatVersion = "$(& $clangFormat --version)".Trim()
+"Using $clangFormatVersion located at $clangFormat" | Write-Host
+
$files = Get-ChildItem -Recurse -LiteralPath "$Root/src" -Filter '*.cpp'
$files += Get-ChildItem -Recurse -LiteralPath "$Root/src" -Filter '*.c'
$files += Get-ChildItem -Recurse -LiteralPath "$Root/include/vcpkg" -Filter '*.h'

add clang-format version to format-cxxcode (#41)