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.
We need a way to create different search databases for branded and unbranded versions of the docs. For example, could the jhindexer task, when running on a branded help set, be aware of the base help set and exclude the base versions of branded files?
Created attachment 8944 [details] Test case - unpack ZIP, configure ${nbroot}, run build.xml, Help -> Contents, search for "modules"
Have it working. Attached ZIP gives a complete working example, but the quick summary: 1. Keep unbranded build script, e.g. nb_all/usersguide/build.xml exactly the same. All changes happen in branding area. 2. f4j_all/usersguide/build.xml (e.g.) would contain a <jhindexer> which: a. Uses basedir/includes from nb_all/usersguide/javahelp b. Sets db to be in f4j_all/usersguide/javahelp c. Includes an additional <brandedfileset> with basedir/includes from f4j_all/usersguide/javahelp (include **/*.html typically) 3. The build script then just creates e.g. f4j_all/usersguide/netbeans/modules/docs/locale/usersguide_f4j.jar with the contents of f4j_all/usersguide/javahelp The new <jhindexer> task, when it sees a <brandedfileset>, behaves a bit differently (see Ant task Javadoc for gory details): 1. All filesets, both the "implicit" unbranded one and all branded ones, are merged together into a temporary directory. 2. During that merge, branding suffixes on (HTML) files are removed; more-specific files like x_f4j.html will overwrite more general files like x.html. 3. The search database is created as usual where you specify. 4. But then the search database files are given the branding suffix too, so that JavaHelp when running inside the branded IDE will pick up the branded database automatically.
Adding I18N keyword just to make it easier to find when looking up branding-related stuff. BTW did not specifically test with localized (JA) files, but should be no different. As now, just include the JA files instead of the plain files, and set locale="ja" on <jhindexer>.
committed Up-To-Date 1.8 nbbuild/antsrc/org/netbeans/nbbuild/JHIndexer.java