You need use IncludeNativeLibrariesForSelfExtract or IncludeAllContentForSelfExtract.
Either use it like this in the .Net CLI:
dotnet publish -r win-x64 /p:PublishSingleFile=true /p:IncludeNativeLibrariesForSelfExtract=true --self-contained true
Either add it in the projectName.csproj file:
<IncludeAllContentForSelfExtract>true</IncludeAllContentForSelfExtract>
In this way, there will be only one exe file and one pdb file after release.
If the response is helpful, please click "Accept Answer" and upvote it.
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.