question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

.well-known folder not published by SDK 2.1.4

See original GitHub issue

Steps to reproduce

Add a .well-known folder and files (such as /.well-known/assetlinks.json) file to the wwwroot of an ASP.NET Core project and publish it.

Expected behavior

The .well-known folder is included in the wwwroot folder output from dotnet publish.

Actual behavior

The .well-known folder is not included.

Environment data

dotnet --info output:

.NET Command Line Tools (2.1.4)

Product Information:
 Version:            2.1.4
 Commit SHA-1 hash:  5e8add2190

Runtime Environment:
 OS Name:     Windows
 OS Version:  10.0.16299
 OS Platform: Windows
 RID:         win10-x64
 Base Path:   C:\Program Files\dotnet\sdk\2.1.4\

Microsoft .NET Core Shared Framework Host

  Version  : 2.0.5
  Build    : 17373eb129b3b05aa18ece963f8795d65ef8ea54

This works in 2.0.3 but does not in 2.1.4.

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Reactions:2
  • Comments:12 (10 by maintainers)

github_iconTop GitHub Comments

5reactions
dasMullicommented, Jan 26, 2018

I’d like an “official won’t-break-again”

fyi I don’t work for MS or .NET Foundation, so nothing I write is official.

My personal suggestion would be to add this in the csproj, without a target:

<ItemGroup>
  <Content Include="wwwroot\.well-known\**" CopyToPublishDirectory="PreserveNewest" Exclude="$(DefaultItemExcludes)" />
</ItemGroup>
1reaction
martincostellocommented, Jan 26, 2018

@dasMulli Thanks - that worked! 🎉

Read more comments on GitHub >

github_iconTop Results From Across the Web

well-known folder not published by SDK 2.1.4 · Issue #9036
well-known folder is included in the wwwroot folder output from dotnet publish . Actual behavior. The .well-known folder is not included.
Read more >
Some files in "wwwroot" folder are not published in ASP. ...
I solved the issue. The solution is to edit the . csproj file. The asterisk will include all the subfolders and files.
Read more >
NETSDK1045: The current .NET SDK does not support ...
This error occurs when the build tools can't find the version of the .NET SDK that's needed to build a project. This is...
Read more >
VS Mac 2019 - Publish to folder - Error
Hi,. I'm using VS Studio on a MacOS Sierra 10.12.6 and I can't easily upgrade the machine to newer OS but it's within...
Read more >
Why is Bamboo dotnet publish running older 2.1 ver...
I have a .net core 2.2 web app that has been building successfully in Bamboo for several months. Recently someone built a new...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found