Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed some problems with tag lib generation #1

Merged
merged 2 commits into from
Jul 10, 2023

Conversation

oheger
Copy link
Contributor

@oheger oheger commented Oct 25, 2017

Hi,

I am a member of the Apache Commons team, and currently I try to do some maintenance work on the Apache Commons Jelly component. A prerequisite for getting out a new release is to get the site build working again. The build uses the maven-jellydoc-plugin to generate the documentation for the various standard tag libs shipped with Jelly. Unfortunately, I hit two major problems:

  • When the plugin was declared and executed in a Maven project of type pom it failed with a FileNotFoundException for the sources directory. The goal is to define the plugin once in the parent project of the several tag lib projects, so that all tag lib documentation can be generated. I was able to fix this problem by skipping the execution for projects that do not have a source directory.
  • For tag libs that contained an abstract tag base class the plugin was throwing a NPE; it generated an empty element in the XML schema document describing the single tags. This has been fixed by doing the check for an abstract class before adding an element to the library.

It would be great if the PR was merged and a new release could be published.
Many thanks!
Oliver

@oheger
Copy link
Contributor Author

oheger commented Feb 24, 2018

Hi,

I understand that you are pretty busy. But would it be possible to give some feedback, so that we can decide how to move on?

Thanks in advance.
Oliver

When the plugin is executed in a project of type pom it throws an
exception because it cannot find the source directory. This is now
suppressed, and no data is generated for this project.

The use case is that there can be multi-module projects defining
multiple tag libs. Then it makes sense to have a parent project (of
type pom) which configures the plugin. The plugin is then applied to
all taglib sub projects. With this patch, this use case is now
supported.
If a tag library contained abstract base classes for tags, the plugin
failed with a NPE in ReferenceRenderer. In this constellation, the
XML schema document contained an empty element without attributes.

This has been fixed by checking for an abstract tag before adding an
element to the library.
Copy link
Member

@basil basil left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the PR!

@basil basil merged commit 0641632 into jenkinsci:master Jul 10, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants