2024-02-22 13:50:55 +01:00
|
|
|
if EXIST %BLENDER_DIR%\lib\windows_x64\llvm\bin\clang-format.exe (
|
|
|
|
|
set CF_PATH=lib\windows_x64\llvm\bin
|
2019-04-16 17:05:31 +02:00
|
|
|
goto detect_done
|
|
|
|
|
)
|
|
|
|
|
|
2024-03-06 15:46:43 +01:00
|
|
|
if EXIST %BLENDER_DIR%\lib\windows_arm64\llvm\bin\clang-format.exe (
|
|
|
|
|
set CF_PATH=lib\windows_arm64\llvm\bin
|
|
|
|
|
goto detect_done
|
|
|
|
|
)
|
|
|
|
|
|
2019-04-16 17:05:31 +02:00
|
|
|
echo clang-format not found
|
|
|
|
|
exit /b 1
|
|
|
|
|
|
|
|
|
|
:detect_done
|
|
|
|
|
echo found clang-format in %CF_PATH%
|
|
|
|
|
|
2022-01-25 09:19:03 -07:00
|
|
|
if NOT EXIST %PYTHON% (
|
|
|
|
|
echo python not found, required for this operation
|
|
|
|
|
exit /b 1
|
2019-08-13 17:03:09 -06:00
|
|
|
)
|
|
|
|
|
|
2023-03-16 17:51:12 -06:00
|
|
|
set FORMAT_PATHS=%BLENDER_DIR%\tools\utils_maintenance\clang_format_paths.py
|
2019-04-16 15:34:32 +02:00
|
|
|
|
|
|
|
|
REM The formatting script expects clang-format to be in the current PATH.
|
2019-04-16 17:05:31 +02:00
|
|
|
set PATH=%CF_PATH%;%PATH%
|
2019-04-16 15:34:32 +02:00
|
|
|
|
2019-08-23 19:35:02 +02:00
|
|
|
REM Use -B to avoid writing __pycache__ in lib directory and causing update conflicts.
|
|
|
|
|
%PYTHON% -B %FORMAT_PATHS% %FORMAT_ARGS%
|
2019-04-16 15:34:32 +02:00
|
|
|
|
2024-06-06 09:10:19 -06:00
|
|
|
call "%~dp0\autopep8.cmd"
|
|
|
|
|
|
2019-04-16 15:34:32 +02:00
|
|
|
:EOF
|