Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ASP.NET Core 3.1 GitThisAssemblyMetadata setting? #108

Closed
Aaron-P opened this issue Mar 6, 2020 · 2 comments · Fixed by #112
Closed

ASP.NET Core 3.1 GitThisAssemblyMetadata setting? #108

Aaron-P opened this issue Mar 6, 2020 · 2 comments · Fixed by #112

Comments

@Aaron-P
Copy link

Aaron-P commented Mar 6, 2020

I have tried setting GitThisAssemblyMetadata to true using a property group in the project .csproj and Directory.Build.props but the ADDMETADATA doesn't get defined. I'm not sure how to get this setting to work with .net core.

TEST.App.csproj.txt

@joacar
Copy link
Contributor

joacar commented Mar 17, 2020

Hi @Aaron-P
Have the same issue. Setting the ADDMETADATA as Conditional compilations symbols (Right click csproj > Properties > Build) explicitly works. Then you can get them

var gitAttributes = typeof(Startup).Assembly.GetCustomAttributes(typeof(System.Reflection.AssemblyMetadataAttribute));

@Aaron-P
Copy link
Author

Aaron-P commented Mar 17, 2020

I manually add the symbol for now, but this question would still matter for the other options that you can set.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants