Summary: | [jar exporter] package.html should not be exported with ".class + resources" | ||
---|---|---|---|
Product: | [Eclipse Project] JDT | Reporter: | Andreas Krüger <andreas.krueger> |
Component: | UI | Assignee: | JDT-UI-Inbox <jdt-ui-inbox> |
Status: | RESOLVED WONTFIX | QA Contact: | |
Severity: | enhancement | ||
Priority: | P3 | CC: | daniel_megert |
Version: | 2.0 | Keywords: | investigate |
Target Milestone: | --- | ||
Hardware: | PC | ||
OS: | Windows 2000 | ||
Whiteboard: |
Description
Andreas Krüger
2002-06-14 12:25:57 EDT
Good point but for 2.0 we are in a mode where we only consider critical bug fixes. Postponing > 2.0 Would a third option (unchecked by default) solve your problem: [] Export package.html ? Please note that we can't filter "overview.html" since this is only a proposed name and not a rule. Daniel: I'd prefer some option [ ] include *.html-files and files from directories "doc-files" By default, this should be unchecked when I'm exporting "generated class files and resources", and checked when I'm exporting "Java source files and resources". - including doc-files is a good point. - including all .htm(l) is not OK (think about a web-project where htmls belong to the binary distribution - the option should not change the other two options and even for source distributions the doc is normally not included (see SDK's src.zip). Thanks again for this good PR. > - including all .htm(l) is not OK Step back a moment and you'll see that we are fighting a Java deficiency. What is not OK is that source code and documentation and resources are all mixed up in the same directory structure. That source code and documentation belong into the same directory structure is something that SUN has cooked up for us. We'll have to eat that stew. Personally, I don't think I have the source code if I don't also have any documentation that goes along with it. You say: > even for source distributions the doc is normally not included When source code is packaged in everyday life, the aim more often than not is that someone who receives the package (usually myself or people from my team) can either understand or develop. In either case, they would want any documentation that goes with the source code. SUN packaging src.zip is not the usual case. Let the documentation that goes with the source code go with the source code. So I want an option [ ] include *.html-files and files from directories "doc-files" , and I want it autofilled to "x" if source code is exported. If you are the rare person exporting SUN's src.zip, you can always uncheck it. (And you'll probably have an ant script anyway.) As a side remark, in Javadoc context, we say ".html" and not ".htm". Compare package.html, also compare what Javadoc generates. Now, on to resources. It's SUN's fault that doc-files and source code is all mixed up. But it's our fault if doc-files/source code and resources are all mixed up. If you set up a web project with .html - resource files and put these resource files into the same directory structure with the source code, you deserve the all those kinds of trouble you are going to run into. I have little mercy with you. What I'm saying: Any project that needs more than a very few resources should have and will have a separate directory structure devoted to resources ONLY. This is certainly the case for a project that has .html - resources. Consider what would happen if not: A project architect that puts .html-resources in the middle of the source code in essence says: "We have no need for javadoc .html files." Looks like a small, unimportant project to me. So, I postulate different directory hirarchy for resource files. I'm not sure how well Eclipse supports that kind of an approach presently. Out of the top of my head, if I had need of a project with nontrivial resources (I admit I presently don't), I would consider split it up into two projects under Eclipse. One has a source folder with the .java sources, the second has a source folder with the resource files. Anyway. If you separate your resources from your source/javadoc, you don't really need to care about the checkbox under consideration. You can just click on or off the entire directory structure containing the resources, as appropiate. If you don't have a separate resource structure, you probably only need something simple, along these lines: "If it doesn't look like javadoc, it's a resouce." Which is exactly what I'm proposing. >That source code and documentation belong into the same directory structure >is something that SUN has cooked up for us. We'll have to eat that stew. Agree. >SUN packaging src.zip is not the usual case. Let the documentation that goes >with the source code go with the source code. So I want an option Not true at all. Also Eclipse does packaging like this - runtime - source - doc & javadoc So I guess Sun and Eclipse are rare examples and are both wrong ;-) >As a side remark, in Javadoc context, we say ".html" and not ".htm". >Compare package.html, also compare what Javadoc generates. I know, but for (Win*) people who read the option it would not be obvious why *.html would be excluded but not *.htm >So, I postulate different directory hirarchy for resource files. >I'm not sure how well Eclipse supports that kind of an approach presently. No problem, but if you select a project which has its resource in proj/resources and the source in proj/source and then export proj with your option checked it would exclude all *.html files from proj/resources. >Out of the top of my head, if I had need of a project with nontrivial >resources (I admit I presently don't), I would consider split it up into two >projects under Eclipse. One has a source folder with the .java sources, >the second has a source folder with the resource files. For Eclipse plug-in developers this would mean to have two plug-ins for one thing. What you're asking for is another feature for I we already have a PR (I think): adding filter support to the JAR file exporter. This would allow you to filter whatever you like. (e.g. *.html, *.doc). > This would allow you to filter whatever you like. (e.g. *.html, *.doc). Please, remember: > - including doc-files is a good point. Proposed fix: [ ] Export Java doc files (package.html, doc-files directory) which will exclude the following from PACKAGE_FRAGMENTS: - directory 'doc-files' (including children) - file 'package.html' Post 2.1 THis is easy to do, just look at the ocmpiler settings in the project properties and on the "Build Path" tab, add the appropriate names. Reassigning to inbox since there are currently no plans to work on this. no plans for this As of now 'LATER' and 'REMIND' resolutions are no longer supported. Please reopen this bug if it is still valid for you. |