I'm trying to call "dotnet publish" with a specific publish profile pubxml file as documented here :
https://docs.microsoft.com/en-us/aspnet/core/host-and-deploy/visual-studio-publish-profiles?view=aspnetcore-2.1&tabs=aspnetcore2x
However, everything I try seems to result in the default behaviour, and the /p:PublishProfile part is ignored.
dotnet publish /p:PublishProfile="MyFolderProfile"
Doesn't work, and logs no error, building to the default location under "/obj".
I do note that an intentionally incorrect command has the same result though, eg:
dotnet publish /p:PublishProfile="MyFolderProfile-XXXXX"
What am I doing wrong? - Any pointers would be greatly appreciated!
I ran into the same issue a while ago. I managed to fix it by instead calling:
dotnet build [projectname] /p:PublishProfile=[PublishProfile]
1.4m articles
1.4m replys
5 comments
57.0k users