run_clang_tidy.ps1 had not been run on Windows before.
- Run native commands through Invoke-Quiet. Under
$ErrorActionPreference = "Stop", Windows PowerShell made CMake's
first stderr line fatal, so configure always failed.
- Pass the --line-filter name with native separators. clang-tidy
matches it against the end of the file's native path, so on Windows
every misc-include-cleaner finding was dropped.
- Decode subprocess output as UTF-8 and let stdout replace characters
it cannot encode. A changed line with text such as 打印 crashed the
script under cp1252.
- Check VCToolsInstallDir and WindowsSdkDir in VsDevCmd's output
before applying it, so a failure names the command to run and leaves
the calling shell untouched.
- Log the git_commit_hash_header build, use -LiteralPath for logs, and
hide VsDevCmd's stderr as build_win.bat does.
On every platform, git quotes non-ASCII paths and appends a tab to a
+++ header whose path contains a space, and parse_diff dropped both.
changed_files and the workflow's changed-files step now pass
core.quotePath=false, and parse_diff strips the tab.
A Linux job configures without the precompiled header and runs clang-tidy over the C++ lines a pull request changes. The only check for now is misc-include-cleaner for missing includes; .clang-tidy is where further checks get enabled.
scripts/run_clang_tidy.sh (Linux, macOS) and scripts/run_clang_tidy.ps1 (Windows) run the same check locally: the same configure, the clang-tidy version pinned in scripts/clang_tidy_requirements.txt, and the same comparison against OrcaSlicer's main. They offer to install what is missing, or print the command to do it by hand.