Bugs item #1150186, was opened at 2005-02-23 22:35
Message generated for change (Tracker Item Submitted) made by Item Submitter
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=402868&aid=1150186&group_id=31650

Category: Tasks
Group: 0.85
Status: Open
Resolution: None
Priority: 5
Submitted By: stj3570 (stj3570)
Assigned to: Nobody/Anonymous (nobody)
Summary: ResGen task does not use dynamicprefix 

Initial Comment:
--- Description ---
The Resgen task is not using the dynamic prefix (passed
through the <resourcefileset>) properly.

Currently it is just prefixing the value of the dynamic
prefix to the resource filename while creating a
.resource file. It does not resolve the complete
subfolder names to generate the appropriate .resource
file. 

--- Steps To Reproduce ---
(see attached repro)
1) Create a resource file Foo.en-us.resx, under the
relative project path .\Bar
2) Compile the resource file using the following NAnt task
 <resgen>
  <resources prefix="Example" dynamicprefix="true">
     <include name="**\*.resx" />
  </resources>
</resgen>

3) Execute NAnt.exe 0.85 in the project root directory

--- Expected Result ---
A file named "Example.Bar.Foo.en-us.resources" should
be created in the subdirectory .\Bar
--- Actual Result ---
The file is incorrectly named
"Example.Foo.en-us.resources" ; the dynamic prefix from
the subdirectory "Bar" is missing.

--- Suggested Fix ---
 
The function ResourceFileSet::GetManifestResourceName()
gets the correct resource name.  It should be used by
the ResGen task.

Edit project file
".\src\NAnt.DotNet\Tasks\ResGenTask.cs" line # 346:

Current Line #346:
> FileInfo outputFile = GetOutputFile(new
FileInfo(filename), Resources.Prefix);

Fixed Line # 346: 
> FileInfo outputFile = new FileInfo(
Resources.GetManifestResourceName(filename, filename));



----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=402868&aid=1150186&group_id=31650


-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click
_______________________________________________
nant-developers mailing list
nant-developers@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nant-developers

Reply via email to