How to use a custom attribute on an assembly in .NET Core 1.1

后端 未结 1 598
耶瑟儿~
耶瑟儿~ 2021-01-04 03:20

While I found this post regarding retrieving a custom attribute on an assembly, I am unsure on how to add a custom attribute to an assembly in .NET Core 1.1. In .NET Framewo

1条回答
  •  陌清茗
    陌清茗 (楼主)
    2021-01-04 03:34

    You can always create a new AssemblyInfo.cs file or any other .cs file to do the same.

    However you can also use the new auto-generated assembly info mechanism. You can add this to your csproj file, replace the value replacing the Include attributes value with the type name of your custom attribute:

    
      
        <_Parameter1>DasMulli.Win32.ServiceUtils.Tests
      
    
    

    0 讨论(0)
提交回复
热议问题