Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Documentation Version Numbers

Murat Engin Aksungur March 31, 2020

Hi Everyone,

We have started using Confluence recently and we need your help on one issue:

We want to advance our documentation process just like in the below.

process.jpg

We want it to continue like v.1-v.1.1-v.1.2.

We would be glad if anyone can tell us how we can do this process.

Thanks,

2 answers

2 accepted

0 votes
Answer accepted
Murat Engin Aksungur April 10, 2020

Hi all,

With the code below, we have successfully created the documentation version numbers.

I am also adding the image.

## @noparams

#set($containerManagerClass=$content.class.forName('com.atlassian.spring.container.ContainerManager') )

#set($getInstanceMethod=$containerManagerClass.getDeclaredMethod('getInstance', null) )

#set( $containerManager=$getInstanceMethod.invoke(null,null) )

#set( $containerContext=$containerManager.containerContext )

#set( $pageManager=$containerContext.getComponent('pageManager') )

#set( $allVersions=$pageManager.getVersionHistorySummaries($content) )

<table>

<tr>

  <th>Tarih</th>

  <th>Version</th>

  <th>Modifiye Eden</th>

</tr>

#foreach( $version in $allVersions )

<tr>

  <td>$action.dateFormatter.formatDateTime($version.getLastModificationDate())</td>




#set ( $cV =  -1+$version.getVersion())

#if ($cV<5)

<td> v1.$cV</td>

#end

#if ($cV>=5 && $$cV<10)

#set($mdx=-5+$cV)

<td>v2.$mdx</td>

#end

#if ($cV>=10)

#set($cdx=-10+$cV)

<td> v3.$cdx</td>

#end




<td>#usernameLink($version.getLastModifierName())</td>

</tr>

#end

</table>

process2.jpg

0 votes
Answer accepted
Matt Reiner _K15t_
Marketplace Partner
Marketplace Partners provide apps and integrations available on the Atlassian Marketplace that extend the power of Atlassian products.
April 1, 2020

Hi @Murat Engin Aksungur ,

I work with the team that makes the Scroll Versions app. There's no great way to control the versioning on a page level, since Confluence handles it automatically, but you could use our app to have a space-wide version, where you can use whatever version numbering you'd like.

We also have this guide for writing documentation in Confluence, which might be helpful for your team: https://www.k15t.com/rock-the-docs

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events