同一个项目,Windows上用dotnet build 可以build成功,
放到Linux上,dotnet build 就会报错:
/usr/share/dotnet/sdk/2.0.0/Microsoft.Common.CurrentVersion.targets(2924,5): error MSB3552: Resource file "**/*.resx" cannot be found.
linux下的路径分割符号是正斜杠(/),而windows是反斜杠(\),如果你的路径有硬编码的分割符,那么可能出现找不到路径。
问题找到了,因为这个项目以前在Windows中部署的,所以有一个文件的名字是反斜杠的\,