I have just released a major update to my Generate Release Notes VSTS Build extension. This V2 update adds support to look back into past releases to find when there was a successful release to a given stage/environment and creates a rollup set of build artifacts, and hence commits/changesets and workitems, in the release notes.
This has been a long running request on GitHub for this extension which I am pleased to have been able to address.
To aid backwards compatibility, the default behaviour of the build/release tasks is as it was before, it can be used in a build or in and release, and if in a release it only consider the artifacts in the current release that ran the task.
If you want to use the new features you need to enable them. This is all on the advanced properties
You get new properties to enable scanning past releases until the task find a successful deployment to, by default, the same stage/environment that is currently being released too. You can override this stage name to allow more complex usage e.g. generating the releases notes for what is changed since the last release to production whist in a UAT environment.
This change also means there is new variable that can be accessed in templates, this $Releases which contains all the releases being used to get build artifacts. This can be used on release notes to show the releases being used e.g.
\*\*Release notes for release $defname\*\*
\*\*Release Number\*\* : $($release.name)
\*\*Release completed\*\* $("{0:dd/MM/yy HH:mm:ss}" -f \[datetime\]$release.modifiedOn) \*\*Changes since last successful release to '$stagename'\*\*
\*\*Including releases:\*\*
$(($releases | select-object -ExpandProperty name) -join ", " )
Generating a content
**Release notes for release Validate-ReleaseNotesTask.Master** **Release Number** : Release-69 **Release completed** 05/01/17 12:40:19 **Changes since last successful release to 'Environment 2'** **Including releases:** Release-69, Release-68, Release-67, Release-66
Hope you find this extension useful