1、netcore2.1.2,swagger.aspnetcore 1.1.0版本。發布netcore項目時swagger的接口文檔xml 遺漏,始終發布不上去。后來查閱資料,講的好像是netcore的一個bug,默認過濾掉一些xml文件。如果需要發布,則需要改動csproj文件或project.json文件。
https://stackoverflow.com/questions/42385162/xml-documentation-file-is-not-included-in-publish-folder
2、修改csproj文件
<PropertyGroup>
<GenerateDocumentationFile>true</GenerateDocumentationFile>
</PropertyGroup>