Using asminfo to include webresources
Sean Wilkening <[email protected]>
| Newsgroups | gmane.comp.windows.dotnet.nant.user |
|---|---|
| Message-ID | <1347C617AE36FE4F9C53B10A8A6289860295A608C704@EXMBXCLUS01.saasmadeeasy.com> |
I currently have a project that we change the version of the dll and other attributes using the <asminfo> task each build. Now we are using WebResources and would like to add those attributes to the same task, but are having errors when executing the task now.
Are WebResources supported in the <asminfo> task or are we doing something wrong?
<asminfo output="ATI.NextGen.Framework/Properties/AssemblyInfo.cs" language="CSharp">
<imports>
<import namespace="System" />
<import namespace="System.Reflection" />
<import namespace="System.EnterpriseServices" />
<import namespace="System.Runtime.InteropServices" />
<import namespace="System.Web.UI" />
</imports>
<attributes>
<attribute type="ComVisibleAttribute" value="false" />
<attribute type="CLSCompliantAttribute" value="true" />
<attribute type="AssemblyFileVersionAttribute" value="${majorversion}.${minorversion}.${CCNetLabel}.${svn.revision}" />
<attribute type="AssemblyVersionAttribute" value="${majorversion}.${minorversion}.${CCNetLabel}.${svn.revision}" />
<attribute type="AssemblyTitleAttribute" value=" NextGen Framework" />
<attribute type="AssemblyDescriptionAttribute" value="Contains all NextGen Framework Code" />
<attribute type="AssemblyCopyrightAttribute" value="Copyright (c) 2010" />
<attribute type="ApplicationNameAttribute" value="NextGen Framework" />
<attribute type="WebResource" value=""ATI.NextGen.Framework.UI.Web.WebControls.GridScripts.js", "application/x-javascript"" />
<attribute type="WebResource" value=""ATI.NextGen.Framework.UI.Web.WebControls.GridCSS.css", "text/css"" />
</attributes>
<references>
<include name="System.EnterpriseServices.dll" />
</references>
</asminfo>
When adding the last two attributes we get the following error:
<builderror>
<type>NAnt.Core.BuildException</type>
<message><![CDATA[AssemblyInfo file 'c:\builds\nextgen_trunk\working\ATI.NextGen.Framework\Properties\AssemblyInfo.cs' could not be generated.]]></message>
<location>
<filename>c:\builds\nextgen_trunk\working\Nant.build</filename>
<linenumber>67</linenumber>
<columnnumber>6</columnnumber>
</location>
<stacktrace><![CDATA[ at NAnt.DotNet.Tasks.AssemblyInfoTask.ExecuteTask()
at NAnt.Core.Task.Execute()
at NAnt.Core.Target.Execute()
at NAnt.Core.Project.Execute(String targetName, Boolean forceDependencies)
at NAnt.Core.Project.Execute()
at NAnt.Core.Project.Run()]]></stacktrace>
<builderror>
<type>NAnt.Core.BuildException</type>
<message><![CDATA[Assembly attribute with type 'WebResource' could not be loaded.]]></message>
<stacktrace><![CDATA[ at NAnt.DotNet.Tasks.AssemblyInfoTask.TypedValueGatherer.GetTypedValue(StringCollection assemblies, StringCollection imports, String typename, String value)
at NAnt.DotNet.Tasks.AssemblyInfoTask.TypedValueGatherer.GetTypedValue(StringCollection assemblies, StringCollection imports, String typename, String value)
at NAnt.DotNet.Tasks.AssemblyInfoTask.CodeProvider.GetTypedValue(AssemblyAttribute attribute, StringCollection assemblies, StringCollection imports)
at NAnt.DotNet.Tasks.AssemblyInfoTask.CodeProvider.GenerateAssemblyAttributesCode(AssemblyAttributeCollection assemblyAttributes, StringCollection imports, StringCollection assemblies, TextWriter writer)
at NAnt.DotNet.Tasks.AssemblyInfoTask.ExecuteTask()]]></stacktrace>
</builderror>
</builderror>
Thanks for your help,
Sean Wilkening
------------------------------------------------------------------------------
Start uncovering the many advantages of virtual appliances
and start using them to simplify application deployment and
accelerate your shift to cloud computing.
http://p.sf.net/sfu/novell-sfdev2dev
_______________________________________________
NAnt-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/nant-users