File tree Expand file tree Collapse file tree 1 file changed +5
-6
lines changed Expand file tree Collapse file tree 1 file changed +5
-6
lines changed Original file line number Diff line number Diff line change @@ -208,14 +208,13 @@ commands that you can specify for compiled languages.
208
208
209
209
codeql database create cpp-database --language=cpp --command=make
210
210
211
- - C# project built using ``dotnet build `` (.NET Core 3.0 or later) ::
211
+ - C# project built using ``dotnet build ``::
212
212
213
- codeql database create csharp-database --language=csharp --command='dotnet build /t:rebuild'
213
+ For C# projects using either `dotnet build` or `msbuild`, you should specify `/p:UseSharedCompilation=false`
214
+ in the build command. It is also a good idea to add `/t:rebuild` to ensure that all code will be built (code
215
+ that is not built will not be included in the CodeQL database):
214
216
215
- On Linux and macOS (but not Windows), you need to disable shared compilation when building C# projects
216
- with .NET Core 2 or earlier, so expand the command to::
217
-
218
- codeql database create csharp-database --language=csharp --command='dotnet build /p:UseSharedCompilation=false /t:rebuild'
217
+ codeql database create csharp-database --language=csharp --command='dotnet build /p:UseSharedCompilation=false /t:rebuild'
219
218
220
219
- Go project built using the ``COEQL_EXTRACTOR_GO_BUILD_TRACING=on `` environment variable::
221
220
You can’t perform that action at this time.
0 commit comments