Shaw, Gerry wrote:

>Wow, I guess I should have read more about Xml namespaces.  Good thing there
>is lots of smart people on this list.
>
>This is really clean Joe/Ian but is there anyway to import a task dll into
>the default namespace using this method?  Ie, I want to "import" a number of
>task assemblies into the default (ie, no prefix) namespace but import
>another into it's own namespace.  Here is some broken syntax that
>demonstrates something like what I want to do.
>
><?xml version="1.0"?>
><project
>    xmlns:default="NAnt.Core.dll"
>    xmlns:default="NAnt.DotNetTasks.dll"
>    xmlns:zip="NAnt.ZipTasks.dll" >
>
>    <echo message="Hello"/>
>    <target name="foo">
>        <csc/>
>        <zip:unzip/>
>    </target>
></project>
>  
>
why not just leave it the way it works currently ie all task libs that 
Nant finds map to the default namespace unless theres a named mapping. 
That way people using the basic tasks, which shouldn't have namespace 
clashing issues, don't need to worry about it. So you only need the 
namespace declaration for special cases. Xml only allows the mapping of 
one default namespace and also will not allow
duplicate namespace declarations. So we may not be able to do what 
you're after with only the namespace syntax. My initial feeling was that 
I'd prefer to have as little of this stuff as possible in the build 
file. Ie let nant find which task libs its using and handle the clashing 
conditions with namespace declarations. Now I'm not so sure. 

Ian

>
>Also it would be nice to be able to specify the strong name for the assembly
>to import.
>
>Another thing to think about is to associate your buildfile with a known
>nant assembly.  Nothing worse than taking an older project and trying to
>build it but have it not work because the version of nant on your system is
>not backwards compatible.  By being tied to a version of nant you would know
>the problem.
>
>
>-------------------------------------------------------
>This sf.net email is sponsored by: OSDN - Tired of that same old
>cell phone?  Get a new here for FREE!
>https://www.inphonic.com/r.asp?r=sourceforge1&refcode1=vs3390
>_______________________________________________
>Nant-developers mailing list
>[EMAIL PROTECTED]
>https://lists.sourceforge.net/lists/listinfo/nant-developers
>  
>


-- 
"The use of COBOL cripples the mind; its teaching should, therefore, be regarded as a 
criminal offence." (Edsger Wybe Dijkstra)




-------------------------------------------------------
This sf.net email is sponsored by: OSDN - Tired of that same old
cell phone?  Get a new here for FREE!
https://www.inphonic.com/r.asp?r=sourceforge1&refcode1=vs3390
_______________________________________________
Nant-developers mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/nant-developers

Reply via email to