Code formatting
Last updated
Was this helpful?
Last updated
Was this helpful?
For automatic formatting of project files, the file format_all_files.bat is located in the root of the repositories.
It essentially calls .clang-format on all project files:
In order for the script to work correctly, you need to add the path to clang-format to your PATH environment variable. The program is located in the Visual Studio directory. 99% that you have the same path:
c:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\Llvm\bin\
In the Windows search, enter environment and open System Properties:
Click on Environment Variables:
Select Path and click on Edit:
Insert the path to clang-format into the list, click on OK:
You can check that everything is ok on the command line using one of the commands:
The output should be as follows:
After that, you can use the script format_all_files.bat