By specifying a custom build event, you can automatically run a command before the build starts or after it completes. In Visual Studio, right-click the project -> Properties to enter the project properties menu.
Build events follow the same syntax as DOS commands. For example, when starting debugging, create a folder in a certain directory
mkdir c:\logs
You can enter the directory about the project more quickly through the built-in macro list
Click [Macro]-》From Select the macro to be inserted in [Macro List] -> click [Insert].
Perform some file operations before/after the project generates events. For example, you can synchronize your configuration files and dynamic library files when writing unit tests; Synchronize Debug and Release files,...
Reference document
(v=vs.140).aspx
The above is the detailed content of A detailed introduction to custom build events in Visual Studio. For more information, please follow other related articles on the PHP Chinese website!