vscode-dev-containers
vscode-dev-containers copied to clipboard
Nuget restore of .NET projects does not include XML docs due to NUGET_XMLDOC_MODE env var from .NET SDK container
- VSCode Version: Version: 1.68.0-insider (c0769274fa136b45799edeccc0d0a2f645b75caf)
- Local OS Version: Windows 11
- Local chip architecture: amd64
- Reproduces in: Remote - Containers
- Name of Dev Container Definition with Issue: dotnet
Steps to Reproduce:
- Set up a devcontainer environment based on the
dotnetdev container, the .NET 6 variant - Perform a
dotnet restorefor any .NET project (it may need to reference a 3rd-party library), observe that IntelliSense docs aren't present for members. Also observe that in~/.nuget/packages/<nuget package name>/<nuget package version>/lib/net6.0there are no XML files - Add
ENV NUGET_XMLDOC_MODE=nonesomewhere in your local devcontainer Dockerfile, to override the setting from the .NET SDK image - Rebuild the dev container
- IntelliSense docs now exist, and XML files are present in nuget package folders
I suspect this could be fixed by adding the above mentioned ENV NUGET_XMLDOC_MODE=none to https://github.com/microsoft/vscode-dev-containers/blob/main/containers/dotnet/.devcontainer/base.Dockerfile, but I'm not sure if that's truly the right file to put it, or where in that Dockerfile it should go.
Thanks for opening this issue.
Opening a PR as you describe above sounds reasonable, cc @joshspicer in case you have any other thoughts.