How to `extern alias` an assembly with .Net core?

后端 未结 4 678
时光取名叫无心
时光取名叫无心 2021-01-04 00:23

TLDR: Everything is pretty much in the title.

Suppose that your project.json uses two packages that have a two types which are named th

4条回答
  •  梦毁少年i
    2021-01-04 00:39

    I believe the issue you are trying to link to is here:
    https://github.com/NuGet/Home/issues/4989

    You can workaround by using an MSBuild Target. drop this snippet into Directory.Build.targets:

    
        
            @(PackageReference->'%(Identity)')
            @(PackageReference->'%(Alias)')
        
    
        
            
                $(AliasName)
            
        
    
    

    and then use it in your csproj in your PackageReference nodes like this:

    
        
    
    

    added this as a comment to the GitHub issue:
    https://github.com/NuGet/Home/issues/4989#issuecomment-426666530

提交回复
热议问题