# version.html > learn how to use the version shortcode If the project you are documenting must be installed, it is likely that your documentation needs to be versioned. In this scenario, it’s especially useful to have a shortcode that can also version your download links, GitHub links, announcements, and similar assets without having to manually update them across all of your articles. How it works # Set up a content/latest directory to begin versioning your documentation. Add the following frontmatter to content/latest/_index.md, updating the version numbers: yaml cascade: version: isLatest: true major: 0 minor: 0 patch: 0 Use the {{}} shortcode to print out the collection’s versions anywhere beneath the directory. Examples # Example Product Theme does not actually have versioned documentation; this is just for demonstration purposes. Local version # The default functionality for this shortcode uses the version numbers cascading from the root of the versioned directory (for example, content/latest, content/1.0.2). 0.0.2 is now live! 0.0.2 Download s - **{{}} is now live!** - [{{}} Download](https://github.com/org/project/releases/tag/v{{}}) Global version # In cases where you want to mention or link to the latest version in older versions of your content, you can add {{}}. This uses the site-wide parameter to determine what version number to use. yaml # Theme Feature Settings params: [...] version: major: 0 minor: 0 patch: 3 0.0.3 is now live! 0.0.3 Download s - **{{}} is now live!** - [{{}} Download](https://github.com/org/project/releases/tag/v{{}}) Source Code # golang {{- $source := index (.Params) 0 | default "local" }} {{- $major := ""}} {{- $minor := ""}} {{- $patch := ""}} {{- $value := ""}} {{- if eq $source "global" }} {{- $major = .Site.Params.Version.Major }} {{- $minor = .Site.Params.Version.Minor }} {{- $patch = .Site.Params.Version.Patch }} {{- else}} {{- $major = .Page.Params.Version.Major }} {{- $minor = .Page.Params.Version.Minor }} {{- $patch = .Page.Params.Version.Patch }} {{- end}} {{- $value = print $major "." $minor "." $patch }} {{- $value }} ## Metadata - **Section**: features - **Type**: features - **Author**: Lawrence Lane - **Parent**: [version.html](/features/shortcodes/index.txt) ## Navigation - **Current Section**: [version.html](/features/shortcodes/index.txt)