OctoPack Release Notes & TeamCity

Hi,

We’ve got our deployments working between TeamCity and Octopus, works great! However, I’d like to now have TeamCity pass the release notes (VCS commit messages) to each package. I thought I could modify the TeamCity Visual Studio Solution build step to pass the following additional command line parameters:

/p:OctoPackReleaseNotes=“This is an injected release note”

However, that does not appear to be getting picked up by OctoPack. Any suggestions?

Thanks,
Brent

Hi Brent,

Thanks for getting in touch! OctoPack can do a few things, but adding release notes is not one of them.
OctoPack and call NuGet to create a NuGet package, and it can also call NuGet to push a package to a NuGet feed or repository.
It cannot store release notes with a package as there is no where for release notes to go.

Octopus can store release notes with a release. And packages are almost always associated with releases.
Using Octo.exe to create-release http://docs.octopusdeploy.com/display/OD/Creating+releases you can either pass release notes as text or assign a file to be your release notes.

So this could be that you are using TeamCity to create a release but using the wrong build step and flag to attach releases notes to the release.

Hope that helps!
Vanessa

Hi Brent,

I was completely and utterly wrong about this one. Octopack can be passed release notes, either as a string or as a file. It as them to the NuSpec and Octopus will read that. If you could grab a build log we might be able to figure this one out. Really sorry about that.

Vanessa

Vanessa,

No problem. Check out the attachments here. I’ve included a build log and a screenshot from our TeamCity build configuration. Take a look and let me know what else I can provide.

Thanks,
Brent

MaintenanceDirect_Build_Package_1.0.292.log (281 KB)

Hi Vanessa,

Any luck or update for us?

Thanks,
Brent

From: Brent Pabst
Sent: Monday, December 8, 2014 8:48 AM
To: 'Vanessa Love’
Subject: RE: OctoPack Release Notes & TeamCity [Questions #3716]

Vanessa,

No problem. Check out the attachments here. I’ve included a build log and a screenshot from our TeamCity build configuration. Take a look and let me know what else I can provide.

Thanks,
Brent

Hi Brent,

Yeah it seems while it’s listed in our documentation as an option it is not actually supported.
I will get it added as an issue but I can’t see it being a super-high priority.
OctoPackReleaseNotesFile does work if you would like to use that in the mean time - it does mean you then need a release notes text file of some description.

Vanessa

Hi, i know this is an old thread, but i have taken a look and the /p:OctoPackReleaseNotes command seems to be working, can you confirm this.

Additionally i am struggling to use the data in the release notes within Octopus. I am trying to define a variable and setting it to $Octopus.Release.Notes but nothing comes through, please advise

Apologies my artifacts were out of sync. I am using a powershell script to manually create a nuspec file, which means i can get the data into the release notes. Question still remains how to use it on the Octopus side

Looks like the Octo.exe has release notes and release notes file properties…if you use the TeamCity plugin and use the Create Release build step, you can specify a file to use for the release notes for that “pre-created” release, instead of trying to pull release notes out of the artifacts.

So far I’ve gotten “changed files” to show up, since its a built-in TeamCity variable for the path to a list of changed files…

E.g., this: WebFormsProject/Default.aspx:CHANGED:313363f8143737f2e44d9ce97e5a05983e5ee8ee

So my step for OctopusDeploy: CreateRelease has this command-line parameter:

–releasenotesfile=%system.teamcity.build.changedFiles.file%

Still looking for a ChangeLog type of thing with commit values instead of files…

Doh! Looks like the Octo folk already nailed this one…just requires a bit of adapting…