bernd@polaris:/opt/Atlassian/jira6$ l atlassian-jira/WEB-INF/classes/templates/jira/project/releasenotes/ total 16K drwxr-xr-x 2 root root 4.0K Aug 21 11:10 . drwxr-xr-x 3 root root 4.0K Aug 21 11:10 .. -rw-r--r-- 1 root root 1.6K Aug 20 13:52 releasenotes-html.vm -rw-r--r-- 1 root root 1.3K Aug 20 13:52 releasenotes-text.vm bernd@polaris:/opt/Atlassian/jira6$
will be used for all projects. In order to have at least a small workaround, I changed the templates to look something like this:
#if($project == "projectX") ## project specific code here #else ## default code here #end
This will work for one or a small amount of projects. However, a monster script will be created sooner or later if there are tens or hundreds of projects needing an individual look for their release notes.
The obvious approach regarding Velocity is to simply parse other templates which contain the specific code. So normally something like this will work with Velocity:
#if($project == "projectX") #parse("project-template.vm") #else #parse("default-template.vm") #end
However, Jira will only load the templates defined by property jira.releasnotes.templates. No other templates will be loaded to the class path which makes it impossible to make some Velocity magic at this place.
So I filed a suggestion at Atlassian here. If you find this issue useful, just vote for it. If you find my workaround useful, just drop me a note.