Reputation: 2750
I am trying to publish my Xamarin.Forms app to the play store and I am walking through the prep doc.
The document says I should include the following code in the AssemblyInfo.cs file.
#if DEBUG
[assembly: Application(Debuggable=true)]
#else
[assembly: Application(Debuggable=false)]
#endif
I looked around but I can only find this file in my obj dirs which means it get's generated during the build. But not in my folder of my android project (the MyApp.Android\obj\debug or release dir)
The comments say this info is outdated but do not refer to how the 2020 way of working should be.
Where do I find this info?
Upvotes: 2
Views: 464
Reputation: 9742
.NET Standard and .NET Core assemblies do not include an AssemblyInfo.cs
anymore (see this question for example, actually this is related to the new Project file format, but I believe that .NET Framework assemblies still contain an AssemblyInfo.cs
even in current versions of Visual Studio). The assembly information properties are now generated from the project file, see the documentation.
Anyway, nothing keeps you from defining an AssemblyInfo.cs
by yourself. Just add the respective file (or another .cs
file, e.g. something in the line of AssemblyProperties.cs
or AssemblyAttributes.cs
) to the project in question and then add the lines to that file. The default action for .cs
files is to compile them, so the respective lines are automatically compiled to your assembly.
Upvotes: 1