Document various tips to iterate faster when building & deploying WSL (#14146)
Blue committed
Feb 3, 2026 at 19:07 UTC
dc82161f7af64e2b449753327f90508332170d03
1 file changed
+29
doc/docs/dev-loop.md
+29
@@ -72,3 +72,32 @@ See [debugging](debugging.md) for general debugging instructions.
72
73
To attach a debugger to the unit test process, use: `/waitfordebugger` when calling `test.bat`.
74
Use `/breakonfailure` to automatically break on the first test failure.
75
+
76
+## Tips and tricks
77
+
78
+**Building and deploying faster**
79
+
80
+To iterate faster, create a copy of [```UserConfig.cmake.sample```](https://github.com/microsoft/WSL/blob/master/UserConfig.cmake.sample):
81
+
82
+```
83
+copy UserConfig.cmake.sample UserConfig.cmake
84
+```
85
+
86
+And uncomment this line:
87
+
88
+```
89
+# set(WSL_DEV_BINARY_PATH "C:/wsldev")
90
+```
91
+
92
+This will change the build logic to build a smaller package that installs faster.
93
+Also see:
94
+
95
+- `WSL_BUILD_THIN_PACKAGE` to build an even smaller package
96
+- `WSL_POST_BUILD_COMMAND` to automatically deploy the package during build
97
+
98
+**Code formatting**
99
+
100
+Every pull request needs to be clang-formatted before it can be merged.
101
+
102
+The code can be manually formatted by running: `powershell .\FormatSource.ps1 -ModifiedOnly $false`.
103
+To automatically check formatting when creating a commit, run: `tools\SetupClangFormat.bat`