Publishing to a relative output folder omits entries from publishOptions
See original GitHub issueSteps to reproduce
I have created a fresh “ASP.NET Web Application (.NET Framework)”, navigated to the folder in a console and ran
dotnet publish -o ..\..\..\..\..\..\tmp\publish -c Release
ordotnet publish -o C:\Users\[...]\tmp\publish -c Release
Expected behavior
Both commands should produce identical results
Actual behavior
The first command doesn’t copy the wwwroot
and Views
folders in the output folder
Environment data
.NET Command Line Tools (1.0.0-preview2-003121)
Product Information:
Version: 1.0.0-preview2-003121
Commit SHA-1 hash: 1e9d529bc5
Runtime Environment:
OS Name: Windows
OS Version: 10.0.10586
OS Platform: Windows
RID: win10-x64
Issue Analytics
- State:
- Created 7 years ago
- Reactions:8
- Comments:11 (2 by maintainers)
Top Results From Across the Web
dotnet publish with relative path not respecting ...
The includes folders are copied across to the publish directory. The expected output is the same as running the command with a full...
Read more >Found multiple publish output files with the same relative ...
Issue: The issue raises after .NET 6 migration. There's a new feature that blocks multiple files from being copied to the same target ......
Read more >Keeping Content Out of the Publish Folder for WebDeploy
I've run into issues with keeping files from publishing with WebDeploy on numerous occasions. When working with large projects it's not ...
Read more >dotnet publish command - .NET CLI
To make publish output go to separate folders for each project, specify a relative path by using the msbuild PublishDir property instead of...
Read more >How to use relative path for publishing destination?
I need to use a relative path to publish PDF output to the same directory level as my project's directory. Hardcoding the path...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I had the same issue. If I use
dotnet publish -c release --output ".\publish"
- not work. If I usedotnet publish -c release --output publish
- work.Find it slightly disturbing that such a fundamental bug has existed for so long, across multiple releases, and has no comment from any team members.