I have successfully been using jenkins to automatically create confluence wiki pages and updating the content using wiki markup.
I specifically use the Jira Issues macro inside a "Wiki Markup" block (which I cannot remember how I created!)
Inside the Wiki Markup block is
This has been working and jenkins can alter the final string - the fixVersion for each new page created as a result on a new jenkins build.
Suddenly this has stopped working and I am seeing very strange behaviour.
Everything works fine if I just press Preview but if I Update (save) the page, then I get corrupted macros.
If I create 2 wiki markup blocks, identical apart from one searches for issuetype of "Defect" and the other searches for "Story".
Then when I save the page, both Jira Gadget links point to the same link, eg: Story.
Why might the Preview work OK as it always has but the saved page is broken?
I compared the page source for the preview against the saved page and the interesting difference is the preview contains a unmigrated-wiki-markup tag.
I have just read
Note: You cannot edit content in wiki markup. Confluence does not store page content in wiki markup. Although you can enter wiki markup into the editor, Confluence will convert it to the rich text editor format immediately. You will not be able to edit the wiki markup after initial entry.
But how can I use the "Confluence Wiki Markup for Macros" if it isn't stored?
If I can no longer achieve this, how else can a wiki page be automatically created with an editable (by jenkins) Jira Issues macro gadget?
This thread sounds similar...
particularly this comment :-
Ah. I just tried a basic test and got the same problem. Looks like a bug on Confluence when entering more than one JIRA issue filter using wiki-markup in that way.
There is definately a bug with multiple jiraissues on a single page.
When I use 'Excerpt' and 'Excerpt Includes' it works and I can get both Stories and Defects shown on the same page.
I have removed the wiki markup and reverted to the actual jira macro.
The only fiddly bit is the macro expects a real value for fixVersion whereas I want to use a BUILD_STR placeholder.
So I create a wiki page with the jira macro and a valid fixVersion which allows me to insert the macro onto the page.
Then I to use the REST API to get the page's storage body into a text file.
I then replace the real fixVersion value with my BUILD_STR placeholder in the text file and update the wiki page using the REST API and the text file.
Bit convoluted but it works and I now have both defects and stories showing in the same wiki page.
Badges are a great way to show off community activity, whether you’re a newbie or a Champion.Learn more
An efficient enterprise content management system, or ECM, is a must-have for companies that create work online (cough cough, all companies). If content calendars, marketing plans, and bu...
Connect with like-minded Atlassian users at free events near you!Find a group
Connect with like-minded Atlassian users at free events near you!
Unfortunately there are no AUG chapters near you at the moment.Start an AUG
You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs