This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
I have several templates which use windows line endings. However, if I create new files using these templates, these files are saved using the unix line endings. When I was using Netbeans 3.5, the line endings of my templates were preserved correctly. I'm using: - Netbeans Q-buid (Build 200311251900) - JDK 1.4.2_02 - Windows XP
The actual template instantiation should be done in openide/loaders. Reassinging to openide for evaluation.
The behaviour depends on implementation of DataObject.createFromTemplate that can be overloaded for individual DataObjects. Impl. in FileEntry [snipped] : while ((current = r.readLine ()) != null) { w.write (frm.format (current)); // Cf. #7061. w.newLine (); } seems to be OK. Now is important to know wich templates do you use.
Once again with question mark. Wich templates do you use ?
No response. Anyway looks like java problem and its IndentFileEntry.createFromTemplate. Please investigate.
Sorry I didn't react, but I thought I would receive mails as soon as someone add extra comments on this issue. But I didn't receive any ... strange ... I did receive such notification mails in the past. I'll upload one of the templates I'm using btw, the problem is still present with this system: - Netbeans build 200402101900 - JDK 1.5.0 beta (build 1.5.0-beta-b31) Maarten
Created attachment 13385 [details] a sample template file
Dane, could you please try to reproduce this on Windows?
I can confirm that this is reproducible on Windows.
It is still reproducible Win XP NB 4.2 dev build 20050816 JDK 1.5.0_04 BTW I found out that the template is in the userdir stored correctly with win line-endings.
*** This issue has been marked as a duplicate of 58236 ***